grub bis (grub-pc and grub 2)

Goh Lip g.lip at gmx.com
Fri Nov 19 07:13:11 UTC 2010


On Friday 19,November,2010 01:51 PM, Thierry de Coulon wrote:
> While I'm on the grub subject...
>
> My main machine (desktop) had several Linux installs. Ubuntu installed grub 2.
> I could then apt-get remove it,

How? "sudo apt-get remove <what?>"


> apt-get-install grub, etc...

How? "sudo apt-get install grub" ?

>
> My laptop only has one Ubuntu installed. When I wanted to remove grub 2,

Again how? "sudo apt-get remove <what?>"

> it said there was no grub 2 installed. I found out "grub-pc" was installed. if I
> try to remove it, it automatically wants to install grub legacy... but there
> is no stage 1... so I tried to ramove grub-legacy to reinstall it... and then
> the system want's to reinstall grub-pc.

That's to prevent you from not having any bootloader at all, so should 
be a good thing, right?


>
> On one side it seems grub 2 and grub-pc are the same thing, but synaptics and
> apt-get clearly see them as two different packages that behave differently.
>

Thierry, you've put this post at a new thread, and it's difficult to 
continue from where you've left off, but both Rashkea and Tom H has 
provided you with sufficient and complete answers that, for me to add 
further would be repeating what they said, but I'll try anyway, with 
apologies to them both.

package "grub" is grub-legacy 0.97
package "grub-pc" is grub2 1.98

This is so users won't confuse between the two.

package "grub2" is 'non-existent' but is 'there' in case users tried to 
install 1.98 but doesn't know about 'grub-pc' as this shows...


pop at timon:~$ apt-cache policy grub
grub:
   Installed: (none)
   Candidate: 0.97-29ubuntu60
   Version table:
      0.97-29ubuntu60 0
         500 http://ubuntu.bytecraft.com.my/ubuntu/ maverick/main amd64 
Packages
pop at timon:~$ apt-cache policy grub-pc
grub-pc:
   Installed: 1.98+20100804-5ubuntu3
   Candidate: 1.98+20100804-5ubuntu3
   Version table:
  *** 1.98+20100804-5ubuntu3 0
         500 http://ubuntu.bytecraft.com.my/ubuntu/ maverick/main amd64 
Packages
         100 /var/lib/dpkg/status
pop at timon:~$ apt-cache policy grub2
grub2:
   Installed: (none)
   Candidate: 1.98+20100804-5ubuntu3
   Version table:
      1.98+20100804-5ubuntu3 0
         500 http://ubuntu.bytecraft.com.my/ubuntu/ maverick/universe 
amd64 Packages


Revisiting your previous thread,

Your first post....
>> I've done it as I usually do, by copying the installation from one partition
>> to another, in this case / went from sda6 to sda1 and /home from sda7 to sda2

When you do something like that...., obviously you know your grub (both 
grub-l and grub2) will not boot.

If in grub-l, you said you'll modify fstab and menu.lst.
Right, I assure you you can do the same in grub2. (but with grub.cfg)
And in both cases whenever you've have 'update-grub' (new kernel or 
whatever), it will create new menu.lst or grub.cfg but with the correct 
parameters, ie., if the device map is correct (which won't be, again for 
both cases, unless there's new version of grub to install)
To create correct device map, you've to "sudo grub-mkdevicemap" (again 
for both case, hmmm, it's getting tiresome).

A better way (both cases) [if you copy your partitions, that is], is not 
to modify menu.lst or grub.cfg but to
sudo grub-mkdevicemap
sudo update-grub

So, I hope this gives you a clearer picture and hope you understand why 
sometimes when somebody says grub-l is better than grub2, some of us 
don't really feel like replying. (it's tiresome)


> Which brings again the question if users, at least in an alternate install,
> should not be able to choose at install time which bootloader they want.
>

I should hope not, otherwise I'll insist they include LILO as well.

> Thierry
>
Take care - Goh Lip






More information about the ubuntu-users mailing list