Pendrive Linux: Difference between revisions

From miki
Jump to navigation Jump to search
No edit summary
Line 17: Line 17:
* Launch ''Startup Disk Creator'' in menu ''System'' → ''Administration''.
* Launch ''Startup Disk Creator'' in menu ''System'' → ''Administration''.
* Select ISO you want to use
* Select ISO you want to use
* Select a free '''FAT32''' partition on your USB drive ({{red|BEWARE! Don't let it erase the partition, because that b*tch will erase the '''WHOLE''' disk}})
* Select a free ''FAT32'' partition on your USB drive ({{red|BEWARE! Don't let it erase the partition, because that b*tch will erase the '''WHOLE''' disk}})
* Select size of ''casper'' file for persistent
* Select size of ''casper'' file for persistent
* ... and let's go.
* ... and let's go.

In case you want several partitions, first create your partitions yourself with e.g. '''gparted''', allocating a free ''FAT32'' for the Ubuntu partition. Eg:
# 1st partition: NTFS<br/>Your data partition
# 2nd partition: FAT32, 2850MB<br/>ie. 850MB for ISO, 2000MB for ''casper-rw'' persistent file

Alternatively you can also use a separate ''casper-rw'' partition:
# 1st partition: NTFS<br/>Your data partition
# 2nd partition: FAT32, 850MB<br/>This is the partition you'll select in the ''Startup Disk Creator''
# 3rd partition: ext3, 2000MB, label ''casper-rw''<br/>For persistent storage

Note that ''Windows XP'' (and maybe later) only shows the first partition on USB drive (because it is seen as a removable media, see [[USB]]). So you should create your data partition as the first partition on the disk.


== Manual recipes ==
== Manual recipes ==

Revision as of 08:58, 1 June 2011

Everything on how to make a persistent Live USB Linux, pen drive linux, install linux on a flash drive, from Windows or Linux...
This page is completely crap.

References

Using Automatic Tools

Universal USB Installer (Windows)

See Universal USB Installer on pendrivelinux.com.

UNetbootin (Windows, Linux)

Startup Disk Creator (Ubuntu)

This is an utility on Ubuntu.

  • Launch Startup Disk Creator in menu SystemAdministration.
  • Select ISO you want to use
  • Select a free FAT32 partition on your USB drive (BEWARE! Don't let it erase the partition, because that b*tch will erase the WHOLE disk)
  • Select size of casper file for persistent
  • ... and let's go.

In case you want several partitions, first create your partitions yourself with e.g. gparted, allocating a free FAT32 for the Ubuntu partition. Eg:

  1. 1st partition: NTFS
    Your data partition
  2. 2nd partition: FAT32, 2850MB
    ie. 850MB for ISO, 2000MB for casper-rw persistent file

Alternatively you can also use a separate casper-rw partition:

  1. 1st partition: NTFS
    Your data partition
  2. 2nd partition: FAT32, 850MB
    This is the partition you'll select in the Startup Disk Creator
  3. 3rd partition: ext3, 2000MB, label casper-rw
    For persistent storage

Note that Windows XP (and maybe later) only shows the first partition on USB drive (because it is seen as a removable media, see USB). So you should create your data partition as the first partition on the disk.

Manual recipes

1st recipe

  • Extract Linux CD in USB root
  • Delete folder [ROOT]
  • Copy the files to USB root:
 menu.c32
 syslinux.cfg
 ubnfilel.txt 		(list of all files on the cd - probably useless)
 ubnpathl.txt		(list of all dir on the cd - probably useless)
  • Copy /casper/vmlinuz to /ubnkern
  • Copy /casper/initrd.lz to /ubninit
  • Use "PDL-Casper-RW-Creator.exe" to create the casper file
  • Then edit D:\syslinux.cfg (where D: is the drive letter of your usb stick), and add "persistent" at the end of the line that begins with "append":
default unetbootin
label unetbootin
  kernel /ubnkern
  append initrd=/ubninit file=/cdrom/preseed/ubuntu.seed boot=casper quiet splash persistent --

Another way to create the persistent file

To create a persistent file (4GB file):

dd if=/dev/zero of=G:\\casper-rw bs=1M count=4090 --progress
mke2fs -b 4090 -L casper-rw G:\\casper-rw

To create a persistent partition:

sudo mkfs.ext3 -b 4096 -L casper-rw /dev/sda1
dd if=/dev/zero of=/media/hda1/casper-rw bs=1M count=128
mkfs.ext3 /media/hda1/casper-rw

Yet another way

  • Created partition: 1 for extract iso, 1 for casper-rw
  • extract the .ISO to usb
  • make the drive bootable:
syslinux -maf X:
  • delete [BOOT]
  • created /syslinux.cfg
  • include /isolinux/isolinux.cfg