[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#378344: marked as done (initramfs-tools: Should be able to force root device for update-initramfs)



Your message dated Mon, 17 Jul 2006 01:56:03 +0200
with message-id <20060716235603.GK22168@baikonur.stro.at>
and subject line Bug#378344: initramfs-tools: Should be able to force root device for update-initramfs
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Package: initramfs-tools
Version: 0.68b
Severity: wishlist

Grub and lilo allow one to set kernel options to force a particular boot
device, and for good reasons.  Unfortunately, update-initramfs does not
sport such a possibility.

E.g., let us assume I bought a new hard disk drive and want to port an
existing /dev/hd?? - System to LVM. It is easy enough to copy the whole
thing to a new filesystem, that lives on LVM on the new drive. But: How do
I come up with that initrd, that boots from LVM on the new disk?

It can be done. One needs to dig down into the internals of mkinitramfs
(disregarding the warning in the manual page that this is not needed for a
local box).

I suggest that this particular thing should be easier. It should be
possible to force a particular boot device via two ways: A "root=" line in
/etc/initramfs-tools/initramfs.conf, and a "-r" option to update-initramfs
(that ought to override the "root=" line).

In passing, either of these would have also helped me working around bug
378332 more elegantly, see
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=378332 .

Regards, and thank you for providing fine software,

Andreas
- --
andreas.krueger@famsik.de
PGP-Schlüssel 0xA207E340 (http://www.pca.dfn.de/dfnpca/pgpkserv/)
Fingerprint B46B C7BA FFEE AD41 35DD  49C3 9D6A E529 A207 E340
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFEuPFPnWrlKaIH40ARAjkUAJ9MqvP9fatBdaMZrVevnmyUcGswiQCcD/h+
nUPVCIlLy8+LRLH3vNeBVyY=
=v2cX
-----END PGP SIGNATURE-----


--- End Message ---
--- Begin Message ---
On Sat, Jul 15, 2006 at 03:44:49PM +0200, Andreas Krüger wrote:
> 
> Grub and lilo allow one to set kernel options to force a particular boot
> device, and for good reasons.  Unfortunately, update-initramfs does not
> sport such a possibility.

usually there is zero reason to do that.
if there is still the dedicated need, because
a) bootloader passes no rootarg
b) hardcoded setup

you can easily hardcode ROOT=/dev/whatever in
/etc/initramfs-tools/conf.d/root
in /etc/initramfs-tools/initramfs.conf

the initramfs will just boot without any root bootarg,
beware that an root bootarg overides this hardcoding.
(initrd-tools compat + repair capability)
 
> E.g., let us assume I bought a new hard disk drive and want to port an
> existing /dev/hd?? - System to LVM. It is easy enough to copy the whole
> thing to a new filesystem, that lives on LVM on the new drive. But: How do
> I come up with that initrd, that boots from LVM on the new disk?

on your newly lvm root you have to fix:
a) /etc/fstab
b) bootloader entry

once the bootloader points to the lvm2 root dev aka /dev/mapper/vgX-root
the box will happily boot from that, provided you have lvm2 installed
there. no need to regenerate the initrd.
if there was previously _no_ lvm2 installed you need to update it
update-initramfs -u
this will go away soonest as lvm2 will get the hooks and regenerate
latest initramfs on install with relevant lvm2 boot scripts.
 
> It can be done. One needs to dig down into the internals of mkinitramfs
> (disregarding the warning in the manual page that this is not needed for a
> local box).

sure mkinitramfs is expert usage.
 
> I suggest that this particular thing should be easier. It should be
> possible to force a particular boot device via two ways: A "root=" line in
> /etc/initramfs-tools/initramfs.conf, and a "-r" option to update-initramfs
> (that ought to override the "root=" line).

nack,
update-initramfs won't be clobbered with all mkinitramfs usage
possbilities.
 
> In passing, either of these would have also helped me working around bug
> 378332 more elegantly, see
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=378332 .

better fix your boot arg than this is just fine,
keeping it open for the lvm2 maintainer when he'll overtake
our hooks for consideration.

best regards

-- 
maks

--- End Message ---

Reply to: