文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>DSL - Installing to a USB Flash Drive

DSL - Installing to a USB Flash Drive

时间:2007-02-02  来源:kingthr

From DSL Wiki

Contents

  • 1 From within Linux
  • 2 From within Linux using GRUB as boot loader
  • 3 From within Windows
  • 4 Convert .iso to USB installation
  • 5 Questions

From within Linux

  • Download the dsl-embedded zipfile
  • Create a FAT16 partition on the pendrive. Mount it.
  • Unzip the dsl-embedded.zip file onto this.
  • Unmount the pendrive
  • run "syslinux -s /dev/sdX1" (without the quotes) to make it bootable.
  • You can now boot via QEMU (from within Linux or windows), OR as native from the USB drive.
  • You can also run DSL from a GRUB bootloader menu on your USB key. This is very useful if you're using DSL as part of a data/system rescue toolkit, as you can include multiple preset configurations of DSL as well as other utilities.

Note: syslinux needs the package "mcopy" included in the package "mtools".

Note: Unfortunately, this method does NOT give a 50MB Linux Distribution because qemu dir and method is (comparatively) big.You will end up with a 110MB distribution.

Note: The iocharset=utf8 option when mounting the USB stick may result in the "KNOPPIX/KNOPPIX" not being found upon booting.

From within Linux using GRUB as boot loader

  • Download the current.iso dsl-cd image.
  • Create an ext2 partition (=> 51MB) on pendrive. Mount it.
  • Change to the directory where you mounted the ext2 partition, install GRUB boot loader:
 grub-install --no-floppy --root-directory=. /dev/<device> 

Note: Replace <device> with the corresponding file which represents your USB storage device.

  • Copy the contents of the cd image to the usb drive.
  • While in the same directory - where you mounted the ext2 filesystem - create a menu.lst file for grub in the directory ./boot/grub/menu.lst
 cat > ./boot/grub/menu.lst << EOF title Damn Small Linux root (hd0,0) kernel /boot/isolinux/linux24 root=/dev/sda1 ro lang=us toram noeject frugal initrd /boot/isolinux/minitrd.gz boot EOF

Note: You might have to change (hd0,0) to the correct partition for your USB drive. However, the default should work on most systems.

  • Unmount the filesystem
  • You can now boot from your USB storage device.

Note: This part may require experts attention and/or a separate page.

From within Windows

Note: This guide assumes that your USB Flash Drive is "I:". Please replace I with the correct drive letter.

  • Format your drive (FORMAT I: /fs:FAT32)
  • Download Syslinux - Syslinux can also be used by various other platforms, such as Unix.
  • Go to a command prompt and run syslinux for your drive (SYSLINUX I:)
  • Download DSL (dsl-embedded.zip), [[1]]
  • Copy DSL to your USB drive & reboot. (Unzip DSL and copy all files)

Note: Booting from USB may or may not work on your computer, mostly dependent on its age and bios setup.

Note: Some systems seem to have problems booting from USB drives formatted as FAT32, changing the format step to FORMAT I: /fs:FAT may allow DSL to boot

Convert .iso to USB installation

With the guide from [2] you can install the .iso contents non-destructiveley onto a USB partition. Leave out all the partitioning or formating stuff to prepare an existing and used USB drive for DSL booting:

  • Mount USB drive, with e.g. mount /dev/sda1 /flash - can be either FAT16 or FAT32!
  • Mount ISO image, with e.g. mount /tmp/dsl-3.2.iso /tmp/iso -o loop
  • Copy all contents from ISO to USB drive: cp -vr /tmp/iso/* /flash/
  • Rename and move syslinux files to root directory: mv /flash/boot/isolinux/* /flash/
  • Rename isolinux.cfg: mv /flash/isolinux.cfg /flash/syslinux.cfg
  • Unmount USB drive: umount /flash
  • Install syslinux: syslinux /dev/sda1 and eventually set the MBR boot flag for this partition (with fdisk).

Note: All path names are examples! Please adapt or you may corrupt existing partitions or files.

Questions

  • Why does the from-within-Linux method require FAT16, but the Windows method work with FAT32? Could I just leave and reuse an existing FAT32 USB partition using the Linux syslinux version?
 * ... probably doesn't
相关阅读 更多 +
排行榜 更多 +
2025pubg国际服最新版本

2025pubg国际服最新版本

飞行射击 下载
pubg国际服地铁逃生最新版本2025

pubg国际服地铁逃生最新版本2025

飞行射击 下载
火柴人大乱斗4游戏

火柴人大乱斗4游戏

飞行射击 下载