. home . news . hacks . fnord . images . allies . santa .

bt4 final persistent usb installation

howto install backtrack 4 final on a usb drive with persistant changes

preperation

get a laptop, a usb thumb drive (& internet) (tip: you might already have a computer and internet, when you can read this text)

partitioning

for partitioning your usb we will take fdisk

fdisk /dev/sdb

to take a look at our usb we do “p”, which prints out our partitiontable.
normally it should be empty, when you followed the cleaning instructions right. if not, delete all partitions until the table is empty, using “d”.

bt partition

to create a new partition we do “n”,we take primary “p”, choose the partition number “1”, and size it to 1600mb

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-15296, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-973, default 973): +1600M

make partition 1 bootable

Command (m for help): a
Partition number (1-4): 1

changes partition

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 2
First cylinder (206-973, default 206):
Using default value 206
Last cylinder, +cylinders or +size{K,M,G} (206-973, default 973): +1600M

3rd volume

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 3
First cylinder (411-973, default 411):
Using default value 411
Last cylinder, +cylinders or +size{K,M,G} (411-973, default 973):
Using default value 973

=== partition types and change the type of the first and last partition to FAT32 using “t”

Command (m for help): t
Partition number (1-4): 1
Hex code (type L to list codes): b
Changed system type of partition 1 to b (W95 FAT32)

Command (m for help): t
Partition number (1-4): 3
Hex code (type L to list codes): b
Changed system type of partition 3 to b (W95 FAT32)

write to disk

looks good, now lets write it on our stick

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.

WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.

creating the filesytems

mkdosfs /dev/sdb1 -n dharma
mkfs.ext3 /dev/sdb2 -L casper-rw
mkdosfs /dev/sdb3 -n larry

NOTE : it is very imported that you name the scond drive “casper-rw”, so backtrack can find the volume with your changes !!!

download

download the backtrack 4 final iso, or wget it

 cd /tmp && wget http://www.backtrack-linux.org/download.php?fname=bt4f

(if does not work try a torrent)

cd /tmp && wget http://www.backtrack-linux.org/bt4-final.iso.torrent

live install

copy the image to a usb using unetbootin,

   1. Plug in your USB Drive (Minimum USB Drive capacity 2 GB)
   2. Format the USB drive to FAT32
   3. Download Unetbootin from http://unetbootin.sourceforge.net/
   4. Start Unetbootin and select diskimage (use the backtrack-final ISO)
   5. Select your USB drive and click “OK” for creating a bootable BackTrack USB drive
   6. Log into BackTrack with the default username and password root / toor.

persistant changes

after you boot your fresh installed backtrack and apply the following, to make your changes persistant.

first mount the second partition on the usb

mkdir /mnt/foo -v
mount /dev/sdb2 /mnt/foo -v

create the changes folder

mkdir /mnt/foo/changes -v

edit the syslinux.cfg

kate /media/cdrom/syslinux.cfg

change the timeout

timeout 23

and copy the following lines under timeout

label btbootin
menu label Backtrack 4 final - persistant changes 
kernel /ubnkern
append initrd=/ubninit BOOT=casper boot=casper persistent rw changes=/dev/sdb2  vga=0x317

done !

now you only need to reboot one more time, and you finally can enjoy your backtrack 4 live with persistant changes on a usb !!!

 
home/bt4_final_live.txt · Last modified: 2010/03/19 18:33 (external edit)