[augeas-devel] [Fwd: [Puppet Users] Re: Augeas and grub.conf]

David Lutterkort lutter at redhat.com
Wed Aug 5 23:16:59 UTC 2009


On Wed, 2009-08-05 at 11:49 +1000, Matthew Palmer wrote:
> On Wed, Aug 05, 2009 at 02:02:07AM +0100, Trevor Hemsley wrote:
> > David Lutterkort wrote:
> > > On Mon, 2009-08-03 at 15:28 +0100, Trevor Hemsley wrote:
> > >   
> > >> In addition, it baffles me a bit as to why the default location for grub.conf is
> > >> /etc/grub.conf when, on Redhat based distros, it is always in /boot/grub/grub.conf
> > >> with a symlink from /etc pointing to it. I think the standard RH installs always
> > >> make /boot a separate partition so this lens will never work.
> > >>     
> > >
> > > IIRC, on Debian it points somewhere else, so we'd need some variation
> > > between RH and Debian. But if there's something that works for either,
> > > and avoids the cross-device symlink I'd like to change the stock lens.
> > >
> > >   
> > I just dug out my old Debian 3.1 DVD and did a minimal install in a VM.
> > I have no /etc/grub.conf at all and the file is actually in
> > /boot/grub/menu.lst with no /boot/grub/grub.conf at all. It's ancient
> > and using Grub 0.95 but I can't find my Debian 4.0 install disks. If the
> > location and file name are the same on later versions then the current
> > grub.aug file is not right at present for that either.
> 
> A new 5.0 (Lenny) install I have here only has /boot/grub/menu.lst, not
> /boot/grub/grub.conf or anything matching /etc/gru*.

Here's the rub: we can't change the Grub module to look for both
menu.lst and grub.conf in /boot/grub, since on Fedora menu.lst is a
symlink for grub.conf, and we'd wind up loading the same file twice into
different places in the tree, with very weird behavior when you make
changes to both copies.

We could add some sort of facility to distinguish between OS's[1] and
load one or the other, depending on OS. I am not perfectly happy with
this solution, since it requires that users check several places in the
tree where grub.conf could show up. Addressing that though would require
some work on mapping trees on load/save, e.g. by adding something to
transforms that expresses 'put the tree under /this/path/here instead
of /files/foo/bar'

Also, if we change away from /etc/grub.conf on OS's where it currently
works, we'd break people's existing code (e.g. Puppet manifests)

David

[1] like in the patches from
https://www.redhat.com/archives/augeas-devel/2009-February/msg00115.html
which I never committed.




More information about the augeas-devel mailing list