update grub + 2 ubtuntu installs with shared /boot

Philip Lawatsch philip at lawatsch.at
Mon Jun 19 09:40:59 UTC 2006


Gary W. Swearingen wrote:
> Philip Lawatsch <philip at lawatsch.at> writes:
> 
>> Gary W. Swearingen wrote:
>>> Philip Lawatsch <philip at lawatsch.at> writes:
>>>
>>>> I've no problem understanding / using grub, I've only got a problem
>>>> understanding all the automatisms which are in ubuntu and deal with grub.
>>> Yeah.  I hear a new Slackware version has come out, or soon.
>> What would slackware have to do with that?
> 
> Oh, just some humor (?) based on my image of typical Slackware users
> not running GNOME or KDE and doing all of their config by editing
> files and avoiding the need to keep up with the "automatisms" de jure
> of GNOME, KDE, Ubuntu, Kubuntu, etc.  These haters of hard-to-keep-
> track-of automatisms are kindred spirits of many BSD users.

Geeeee.
As a long time (happy) slackware user I can honestly tell you that your
image of slackware users is pretty wrong.
I only abandoned slackware because of Pats, well, too 'conservative'
policy regarding packages (kernel, glibc etc). And the drop of gnome
(kde is still included though) was the final reason to leave (see?
Slackware users want shiny desktops too).

>>> And thus two /boot dirs, which I thought you said you didn't want.
>> Yes, I do not want that, and thus would like to know how to avoid it
>> (while still getting new kernels automatically installed into my boot
>> system)
> 
> Can't be done with standard installers, IMO.  With one /boot
> partition, the two Ubuntu installs interfere and/or upgrade-grub
> fails.  Either live with multiple "/boot" (why not?) using your
> grub-on-partition scheme or write a custom upgrade-grub to run after
> install from any OS, or hand edit.

Well, I'll have to live with that then. The only reason why I do not
want multiple /boot is to keep things simple.

>> I currently only have one menu.lst.
> 
> Which won't work automatically, without a custom script.

I now know that :(

>>> You could then edit that to boot the two
>>> ubuntus directly.  
>> How?
> 
> Simply edit the BSD (or whatever OS with your single grub) menu.lst so
> each entry gives the proper "root" which holds that kernel, etc.

????
With 'that kernel' do you mean bsd or linux kernel?
If you mean linux kernel, then this is what I want to avoid. I want to
be able to boot a new kernel which comes from an apt-get upgrade without
every touching anything related to grub myself.

> Almost like how, after my Kubuntu install, the installer created a new
> menu.lst (in its filesystem, in this case) which had entries for that
> Kubuntu plus entries for my obsolete Ubuntu, etc.  (Sadly, it was
> missing entries for my BSDs, requiring hand editing.  It treats MSFT
> OSes more kindly, I hear. :( )
> 
> Oh. Maybe you're asking how to make grub boot a partition (as opposed
> to a kernel)?  I don't know, but I'd be VERY suprised if grub can't
> do that.  I can't check because I seem to be missing many "info"
> files.  If grub won't, use FreeBSD's basic bootloader (or MSFT's).

No, grub can do that just fine.

>> For booting the correct kernel the grub in the mbr would have to know
>> which kernel to boot. And I can only manually update if I have two
>> different ubuntu installs being booted from this one grub. Thats the
>> thing I was asking about in the first place!
> 
> I don't understand that second sentence, unless by "manually", you
> mean "run update-grub".  I mean "edit menu.lst" (from your BSD or
> whatever OS you maintain grub with).

Yes, and I want to 'avoid' having to edit menu.lst every time a security
update comes along.

>>> And I'd probably not even bother installing the
>>> extra bootloaders to the partitions.  But if you do, you don't even
>>> need grub in the MBR; you can use the much simpler BSD bootloader
>>> which simply offers you a choice of partitions (or second disk) to
>>> boot from.
>> Sure I'd have to have a grub install for every ubuntu install if I want
>> an apt-get upgrade to automagically upgrade my config to boot an
>> upgraded kernel. Or is there an alternative to that?
> 
> If booting only from the MBR (with only one /boot/grub), you'd need to
> hand edit menu.lst (or run a custom script to sus out other kernels on
> other partitions - problematic) to boot desired kernels.  Of course,
> this would have to be done after kernel upgrades (unless you use some
> file renaming tricks).
> 
> But it sounds like you want automatic more than you want a single
> /boot, so why not let each OS keep it's own /boot and install grub
> to each OSes partition and have the MBR bootloader boot a partition.
> Then your kernel upgrades will be available automatically without
> changing the MBR bootloader (or its menu.lst, if any).

Yes, will do that. Perhaps I'll one day have time to hack update-grub to
do what I want :)

Aw, thanks for the help

kind regards Philip





More information about the ubuntu-users mailing list