macpentester
08-01-2008, 11:57 PM
I know that there have been several threads created about installing BT3 Final to a Mac, but I tried three times unsuccessfully, but the fourth time I got it done. I have borrowed much of the information that I will be sharing from the following people: jeroenimo, Action discrete, Super n00b, and pureh@te.
FYI before I get started, I installed BT onto an Intel Mac Mini. And as always BACKUP YOUR HARD DRIVE (that means make an image of the Macintosh HD if you need to restore it, which I did the first time I messed up, but then I realized that I hadn't deleted data, just messed rEFIt up beyond recognition!)
I did not make a swap partition because I heard that I did not need to since I had a gig of RAM.
I am skipping the swap part because I did not need it (so have at least a gig of RAM), so if anyone needs my help on that I think that I am not of much assistance because I tried that and it did not work out for me.
Let's get started:
Make a 5 gig boot camp partition.
Download and install rEFIt, making sure that you read the documentation extensively so that you know it like the back of your hand.
Insert the BT3 Final CD.
Restart your computer (for me rEFIt did not show up the first time, so restart again and it will appear).
Select the rEFIt partition tool and make sure that you carefully read the tables and then sync them.
Boot the LiveCD of BackTrack (choose VESA KDE immediately).
Once you get to the desktop, open up a shell.
fdisk /dev/sda
Hit p
You should see the Boot Camp partition as sda3 (it will say something like W95 FAT).
If you only have OS X on your drive then you will see an EFI partition and an "unknown" partition (which is OS X).
Hit t.
Partition number (1-3):
Hit 3.
Hex code (type L to list codes):
Hit 83.
Hit w.
Now this part is important, make sure that the following command works (it should just act as if nothing happened, like you hit enter. To check if it worked successfully, type "mount" without the quotes at the Konsole).
umount /dev/sda3
Now it's time to make the filesystem.
mkfs.ext3 /dev/sda3
Now we install BackTrack.
mkdir /mnt/backtrack
mount /dev/sda3 /mnt/backtrack/
mkdir /mnt/backtrack/boot/
cp --preserve -R /{bin,dev,home,pentest,root,usr,etc,lib,opt,sbin,va r} /mnt/backtrack/
mkdir /mnt/backtrack/{mnt,proc,sys,tmp}
mount --bind /dev/ /mnt/backtrack/dev/
mount -t proc proc /mnt/backtrack/proc/
cp /boot/vmlinuz /mnt/backtrack/boot/
That was pureh@te's code modified in one way, we did not have to make a root or swap partition.
Finally we get to editing the lilo.conf file.
chroot /mnt/backtrack/ /bin/bash
nano /etc/lilo.conf
Now here is my lilo.conf file:
lba32
boot = /dev/sda3
prompt
timeout=60
change-rules
reset
vga=791
image = /boot/vmlinuz
root = /dev/sda3
label = BT3
Now we are ready to execute lilo.
lilo -v
Now we exit the chroot environment and we reboot the system.
exit
reboot
If something goes wrong right off the bat that means you were not very careful in checking each of these commands entered.
When I installed it (which just so happened to be about two hours ago), I was having trouble with rEFIt so I did not trust it, which meant that I used the Boot Camp boot menu to choose the LiveCD before i installed it, but that was because I had messed up my other three times. So what I did was first try the Boot Camp menu, which did not work (i selected Windows, because I only had Mac and Linux on it), so then I tried rebooting and using rEFIt, which worked! However, I played around with BackTrack and then I rebooted it and I could not get back in to it. The solution was to boot into OS X and reboot from there and then boot into rEFIt.
If you have a lot of trouble with this, then delete the partition with Boot Camp Assistant and start over from the beginning.
Hopefully this helps all the other people out there like me!
FYI before I get started, I installed BT onto an Intel Mac Mini. And as always BACKUP YOUR HARD DRIVE (that means make an image of the Macintosh HD if you need to restore it, which I did the first time I messed up, but then I realized that I hadn't deleted data, just messed rEFIt up beyond recognition!)
I did not make a swap partition because I heard that I did not need to since I had a gig of RAM.
I am skipping the swap part because I did not need it (so have at least a gig of RAM), so if anyone needs my help on that I think that I am not of much assistance because I tried that and it did not work out for me.
Let's get started:
Make a 5 gig boot camp partition.
Download and install rEFIt, making sure that you read the documentation extensively so that you know it like the back of your hand.
Insert the BT3 Final CD.
Restart your computer (for me rEFIt did not show up the first time, so restart again and it will appear).
Select the rEFIt partition tool and make sure that you carefully read the tables and then sync them.
Boot the LiveCD of BackTrack (choose VESA KDE immediately).
Once you get to the desktop, open up a shell.
fdisk /dev/sda
Hit p
You should see the Boot Camp partition as sda3 (it will say something like W95 FAT).
If you only have OS X on your drive then you will see an EFI partition and an "unknown" partition (which is OS X).
Hit t.
Partition number (1-3):
Hit 3.
Hex code (type L to list codes):
Hit 83.
Hit w.
Now this part is important, make sure that the following command works (it should just act as if nothing happened, like you hit enter. To check if it worked successfully, type "mount" without the quotes at the Konsole).
umount /dev/sda3
Now it's time to make the filesystem.
mkfs.ext3 /dev/sda3
Now we install BackTrack.
mkdir /mnt/backtrack
mount /dev/sda3 /mnt/backtrack/
mkdir /mnt/backtrack/boot/
cp --preserve -R /{bin,dev,home,pentest,root,usr,etc,lib,opt,sbin,va r} /mnt/backtrack/
mkdir /mnt/backtrack/{mnt,proc,sys,tmp}
mount --bind /dev/ /mnt/backtrack/dev/
mount -t proc proc /mnt/backtrack/proc/
cp /boot/vmlinuz /mnt/backtrack/boot/
That was pureh@te's code modified in one way, we did not have to make a root or swap partition.
Finally we get to editing the lilo.conf file.
chroot /mnt/backtrack/ /bin/bash
nano /etc/lilo.conf
Now here is my lilo.conf file:
lba32
boot = /dev/sda3
prompt
timeout=60
change-rules
reset
vga=791
image = /boot/vmlinuz
root = /dev/sda3
label = BT3
Now we are ready to execute lilo.
lilo -v
Now we exit the chroot environment and we reboot the system.
exit
reboot
If something goes wrong right off the bat that means you were not very careful in checking each of these commands entered.
When I installed it (which just so happened to be about two hours ago), I was having trouble with rEFIt so I did not trust it, which meant that I used the Boot Camp boot menu to choose the LiveCD before i installed it, but that was because I had messed up my other three times. So what I did was first try the Boot Camp menu, which did not work (i selected Windows, because I only had Mac and Linux on it), so then I tried rebooting and using rEFIt, which worked! However, I played around with BackTrack and then I rebooted it and I could not get back in to it. The solution was to boot into OS X and reboot from there and then boot into rEFIt.
If you have a lot of trouble with this, then delete the partition with Boot Camp Assistant and start over from the beginning.
Hopefully this helps all the other people out there like me!