Loading

Monday, July 27, 2009

Installing Backtrack 3 to a harddrive

I started with a clean drive, so you might have to manipulate your partition tables. I’m going to assume that you’re comfortable working with partition tables. If not, work on your google-fu.

Here are the steps I took to install Backtrack 3 on to my laptop harddrive

1. Boot system from Backtrack 3 CD.

2. Once booted, open a terminal and type cfdisk

3. Create these 3 partitons:

A. sda1=/boot
B. sda2=swap
C. sda3= /

NOTE: Format A and C using mkfs.ext3 /dev/sda1 and mkfs.ext3 /dev/sda3.

4. Boot your live CD and open a bash shell and begin. If your swap is not yet made then do this..(otherwise omit this step)

bt~# mkswap /dev/sda2
bt~# swapon /dev/sda2

5. Starting installation

bt~# mkdir /mnt/backtrack
bt~# mount /dev/sda3 /mnt/backtrack/
bt~# mkdir /mnt/backtrack/boot/
bt~# mount /dev/sda1 /mnt/backtrack/boot/

(note: If you only have one partiton to install backtrack to simply omit this step)

bt~# cp --preserve -R /{bin,dev,pentest,usr,etc,lib,opt,sbin,var,root} /mnt/backtrack/
bt~# mkdir /mnt/backtrack/{mnt,proc,sys,tmp,boot,root}
bt~# mount --bind /dev/ /mnt/backtrack/dev/
bt~# mount -t proc proc /mnt/backtrack/proc/
bt~# cp /boot/vmlinuz /mnt/backtrack/boot/

6. Now for lilo.

bt~# chroot /mnt/backtrack/ /bin/bash
bt~# nano /etc/lilo.conf

7. Now I like to delete all the BS in the lilo config file so here is what mine would look like. (remember to set your own VGA accordingly )

lba32
boot /dev/sda
prompt
timeout=60
change-rules
reset
vga=791
image = /boot/vmlinuz
root = /dev/sda3
label = backtrack3_final

GRUB users (Thanks to drwalter)

title Backtrack 3 KDE
rootnoverify (hd0,2)
kernel /boot/vmlinuz vga=791 root=/dev/sda3 ro autoexec=xconf;kdm
boot

title Backtrack 3
rootnoverify (hd0,2)
kernel /boot/vmlinuz vga=791 root=/dev/sda3 ro
boot

REMEMBER: hd0,2 would be for partition 3 NOT 2. Change accordingly!

Excellent. Save that and then execute lilo (I like to use the verbose flag)

bt~# lilo -v

after that exit your chroot enviorment

bt~# exit

and reboot and cross your fingers

bt~# reboot


BackTrack links

No comments:

Post a Comment