Can't install grub and root in same partition [Solved]

If you are new to Linux or new to Sabayon Linux and just not sure where to post, here ya go. Post without fear of being told to RTFM :-)

Moderator: Moderators

Can't install grub and root in same partition [Solved]

Postby searcher1 » Fri May 14, 2010 9:39

I have PCLinuxOS's grub in my MBR and I would like to put Sabayon's grub in the same partition as root. I can't find any option to do this in the graphical install. So far I have installed root in sda8 of my HD and I followed the instructions here:

http://forum.sabayon.org/viewtopic.php?f=50&t=20213

and here:

http://joostruis.blogspot.com/

I have also configured the grub in my MBR according to the instructions here:

http://forum.sabayon.org/viewtopic.php?f=50&t=20179&p=115038#p114625

Although the MBR bootloader shows the option for Sabayon and selecting it does bring me to Sabayon (I think), I can't get Sabayon to boot.

I find the Sabayon live DVD very interesting and would very much like to install it in my HD. I am quite new to Linux so please be patient with me for being so lost.

Many thanks for any assistance.
searcher1
Baby Hen
 
Posts: 7
Joined: Thu May 13, 2010 15:09

Re: Can't install grub and root in same partition

Postby Fitzcarraldo » Fri May 14, 2010 23:25

PCLinuxOS uses Grub1 (a.k.a. Grub Legacy) whereas SL uses Grub2. Grub Legacy uses the disk numbering scheme: 0 = 1st disk, 1 = 2nd disk, and so on, and uses the partition numbering scheme: 0 = 1st partition, 1 = 2nd partition, and so on. Grub2 uses the same disk numbering scheme as Grub Legacy but uses the partition numbering scheme: 1 = 1st partition, 2 = 2nd partition, and so on. Are you sure you have got these configured that way?

You might also find helpful the section titled "Dual boot: two operating systems with GRUB legacy & GRUB 2 mix" in the Ubuntu tutorial GRUB 2 bootloader - Full tutorial.

BTW, the update-grub command mentioned on Web pages regarding Grub2 in Ubuntu is the equivalent to the command grub-mkconfig -o /boot/grub/grub.cfg in SL.
User avatar
Fitzcarraldo
Sagely Hen
 
Posts: 7981
Joined: Sat Mar 10, 2007 5:40
Location: United Kingdom

Re: Can't install grub and root in same partition

Postby searcher1 » Sat May 15, 2010 7:52

Thanks for the reply. I tried the instructions in the Grub2 tutorial website as you suggested, especially the

Code: Select all
sudo install-grub /dev/sdaxx


but it didn't work. I even tried to create another partition for Sabayon's grub, which also didn't work. I was on the verge of giving up when I decided to reinstall one last time.

This time I noticed that in the one of the last installation windows that deals with the bootloader, there is an advanced bootloader options checkbox. I went there, and that's where there's the choice between installing grub into either the MBR or the root partition! I could have done this earlier and saved myself so much grief.

Since then I have completed the installation, rebooted and am now sending this from my beautiful new Sabayon! It has been a journey of trial and error since I started using Linux and along the way I have learnt so much. Thank you for helping me in my learning process.
searcher1
Baby Hen
 
Posts: 7
Joined: Thu May 13, 2010 15:09

Re: Can't install grub and root in same partition

Postby Fitzcarraldo » Sat May 15, 2010 14:31

Good to know you got it working.

If I recall correctly, the Anaconda Installer choice is "first sector of boot partition", not "first sector of root partition". They will be the same partition if you have not created separate /boot and / (root) partitions.

Example 1: If you were to create only the partitions /dev/sda5, /dev/sda6 and /dev/sda7 for, respectively, swap, /boot and /, and you then told the Installer to install the Grub boot loader in the first sector of the boot partition instead of the MBR, the Installer would install the boot loader in /dev/sda6 (not in /dev/sda7).

Example 2: If you were to create only the partitions /dev/sda3 and /dev/sda4 for, respectively, swap and /, and you then told the Installer to install the Grub boot loader in the first sector of the boot partition instead of the MBR, the Installer would install the boot loader in /dev/sda4. This is because the directory /boot is on the root partition in this case.

Why, and how to add "[Solved]" to your post. Please read. I'll do it for you this time.
User avatar
Fitzcarraldo
Sagely Hen
 
Posts: 7981
Joined: Sat Mar 10, 2007 5:40
Location: United Kingdom

Re: Can't install grub and root in same partition [Solved]

Postby searcher1 » Sat May 15, 2010 15:34

Thanks Fitzcarraldo. Sorry I didn't put the [Solved] on the subject line. I'll remember to do so in future.

My Sabayon Grub is now in the same partition as root, which was what I wanted to do from the outset. Your post has taught me something new. In my system setup, the Sabayon root and boot are now in sda 8. I tried to create a small partition in sda 8 for the boot and another big partition for root in sda 9, but the installer couldn't (or refused to) format sda 9. Maybe I did something wrong? After that I deleted both sda 8 and 9, reformatted and reinstalled everything in sda 8. That's when I discovered the option to install boot and root in the same partition.

Anyway I have run into another problem and can't seem to find a solution anywhere. I've made another posting in the Beginners/Newbies Area under the subject "Windows colours have become inverted."
searcher1
Baby Hen
 
Posts: 7
Joined: Thu May 13, 2010 15:09


Return to Beginners|Newbies Area

Who is online

Users browsing this forum: No registered users and 5 guests

cron