I've just installed Backtrack on my harddrive (got one), i also got Fedora and Windows 7. However, now i get the Backtrack-GRUB instead of my Fedora GRUB. How do i change that? I got a sda5 containing my Fedora GRUB so it should be easy to 'rewire' - i don't know how tho.
This is my first instinct as a long-time Gentoo user:
Mount the partition(s) with grub on it:
mount /dev/sda5 /mnt/fedora # if Fedora had a separate /boot: mount /dev/sda923 /mnt/fedora/boot
and copy the relevant section in
$FEDORA/boot/grub/grub.conf into your Backtrack
grub.conf. Not Fedora, but quick and easy.
Mount the proc filesystem so that Fedora will see it too:
mount -t proc none /mnt/fedora/proc
Chroot into Fedora:
Here should come some magic to sanitize the chroot environment, I have no idea how that should look like in Fedora. This is Gentoo:
source /etc/profile && env-update
Now, fire up grub:
Grub commands copied from the Gentoo page:
Code Listing 2.8: Installing GRUB in the MBR grub> root (hd0,0) (Specify where your /boot partition resides) grub> setup (hd0) (Install GRUB in the MBR) grub> quit (Exit the GRUB shell)
(hd0) is the first hard drive, and
(hd0,0) is the first partition on it.
/dev/sda5 usually comes out as
(hd0,4), but make sure to double-check everything as you go along. Grub has auto-complete, so it should be easy.
A word of advice, whichever route you take: when you remove either distro, make sure you remember where your system boots from!
Backtrack probably overwrite the MBR with its records, thus causing the Backtrack GRUB to show up instead of the Fedora one. Now to bring back the Fedora GRUB you need to tell
grub to create appropriate records in the MBR.
See the question restore suse grub for how to restore GRUB. You didn't mention if you are using Grub Legacy or Grub 2, but if both your Fedora and Backtrack installations use Grub 2 you can (from my answer on the linked question):
- Boot into Backtrack
- Mount Fedora somewhere, say
grub-setup -d /mnt/fedora /dev/sda