[opensuse] Why is root device hardcoded in initrd and how could it be prevented?
Hello: Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one: "Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)" The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd. Why is the root device hardcoded in initrd? How could this hardcoding be prevented? Thanks, Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Istvan Gabor wrote:
Hello:
Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one:
"Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)"
The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd.
Why is the root device hardcoded in initrd? How could this hardcoding be prevented?
Hello Istvan AFAIK, it's not actually "hardcoded", but generated during the installation. It's annoying, but the work-around is to rebuild the initrd when you clone a system. /Per -- Per Jessen, Zürich (5.6°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Mon, 18 Jan 2010, Per Jessen wrote:
Istvan Gabor wrote:
Hello:
Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one:
"Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)"
The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd.
Why is the root device hardcoded in initrd? How could this hardcoding be prevented?
Hello Istvan
AFAIK, it's not actually "hardcoded", but generated during the installation. It's annoying, but the work-around is to rebuild the initrd when you clone a system.
... or use mount by label/uuid. Steffen -- Das Nichtrauchen entfernt uns von der Zivilisation und setzt den Mann mit seinem Dackel gleich. -- J. C. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 2010/01/18 13:46 (GMT+0100) Steffen Winterfeldt composed:
On Mon, 18 Jan 2010, Per Jessen wrote:
AFAIK, it's not actually "hardcoded", but generated during the installation. It's annoying, but the work-around is to rebuild the initrd when you clone a system.
... or use mount by label/uuid.
A true clone will not have a unique UUID. I use only EXT3 and generate a new UUID for the clone with tune2fs. -- "Our Constitution was made only for a moral and religious people. It is wholly inadequate to the government of any other." John Adams, 2nd US President Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://fm.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Monday, 2010-01-18 at 13:46 +0100, Steffen Winterfeldt wrote:
... or use mount by label/uuid.
Grub does not "mount" anything. And it does not use label/uuid, AFAIK. The kernel does. - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) iEUEARECAAYFAktUe2MACgkQtTMYHG2NR9UB7gCcC4MItae4ECZFBRzeM2cwCxq1 Bo4Al0p70pLyNute2EzuGO80CiZ4YOo= =doY9 -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
2010. január 18. 13:41 napon Per Jessen <per@opensuse.org> írta:
Istvan Gabor wrote:
Hello:
Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one:
"Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)"
The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd.
Why is the root device hardcoded in initrd? How could this hardcoding be prevented?
Hello Istvan
AFAIK, it's not actually "hardcoded", but generated during the installation. It's annoying, but the work-around is to rebuild the initrd when you clone a system.
Yes, I tried it. I have two problems with this solution: 1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running? 2. I used the install DVD to boot the copied system and ran mkinitrd. This solution worked but the new initrd can boot only in text mode, graphical boot mode is lost. There is a graphical message window but after that step booting always continues in text mode. How can I make an initrd image that allows graphical boot? Thanks, Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 18/01/10 14:52, Istvan Gabor wrote:
Yes, I tried it. I have two problems with this solution:
1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running?
Boot off a rescue system, chroot into the drive, mkinitrd should work.
2. I used the install DVD to boot the copied system and ran mkinitrd. This solution worked but the new initrd can boot only in text mode, graphical boot mode is lost. There is a graphical message window but after that step booting always continues in text mode. How can I make an initrd image that allows graphical boot?
try mkinitrd -s 1024x768 (or whatever resolution you want) - look at man 8 mkinitrd. Regards, Tejas -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Tejas Guruswamy wrote:
On 18/01/10 14:52, Istvan Gabor wrote:
Yes, I tried it. I have two problems with this solution:
1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running?
Boot off a rescue system, chroot into the drive, mkinitrd should work.
I see Istvans problem - he is cloning systems, and that would make the process very tiresome. No, I don't know who to build an initrd for a system that isn't running. I think maybe Steffens suggestion of mounting root by label is what to do. /Per -- Per Jessen, Zürich (5.4°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
2010. január 18. 16:15 napon Tejas Guruswamy <masterpatricko@gmail.com> írta:
On 18/01/10 14:52, Istvan Gabor wrote:
Yes, I tried it. I have two problems with this solution:
1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running?
Boot off a rescue system, chroot into the drive, mkinitrd should work.
I have tried it, not from the rescue disk but from within another running system, and I could not manage it. It gave some error messages which I can't recall. Could you please give step by step instructions? It would be very helpful. Or any link to a howto.
2. I used the install DVD to boot the copied system and ran mkinitrd. This solution worked but the new initrd can boot only in text mode, graphical boot mode is lost. There is a graphical message window but after that step booting always continues in text mode. How can I make an initrd image that allows graphical boot?
try mkinitrd -s 1024x768 (or whatever resolution you want) - look at man 8 mkinitrd.
Yes, I used exactly the above option and parameter but it had no effect. But I will check it once more. Thanks, Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Monday, 2010-01-18 at 17:05 +0100, Istvan Gabor wrote:
2010. január 18. 16:15 napon Tejas Guruswamy <> írta:
On 18/01/10 14:52, Istvan Gabor wrote:
Yes, I tried it. I have two problems with this solution:
1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running?
Boot off a rescue system, chroot into the drive, mkinitrd should work.
I have tried it, not from the rescue disk but from within another running system, and I could not manage it. It gave some error messages which I can't recall. Could you please give step by step instructions? It would be very helpful. Or any link to a howto.
More or less: mount /target_partition. mount --bind /proc /target_partition/proc mount --bind /sys /target_partition/sys mount --bind /dev /target_partition/dev chroot /target_partition You might have to edit /target_partition/etc/mtab. Then, run mkinitrd whatever. Remember that those directories (proc, sys, dev) in the target should be empty before the binding. - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) iEYEARECAAYFAktUikgACgkQtTMYHG2NR9W0owCeKGdWql3vv23GbAFvMwZKMaJp ukgAn2CwcbaYnfRfMyrdC8RFYpj/ORO0 =wa4V -----END PGP SIGNATURE-----
2010. január 18. 17:20 napon "Carlos E. R." <robin.listas@telefonica.net> írta:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On Monday, 2010-01-18 at 17:05 +0100, Istvan Gabor wrote:
2010. január 18. 16:15 napon Tejas Guruswamy <> írta:
On 18/01/10 14:52, Istvan Gabor wrote:
Yes, I tried it. I have two problems with this solution:
1. I don't know how to make an initrd image to the system if it is not running. Do you know how to create initrd image for a system which is not running?
Boot off a rescue system, chroot into the drive, mkinitrd should work.
I have tried it, not from the rescue disk but from within another running system, and I could not manage it. It gave some error messages which I can't recall. Could you please give step by step instructions? It would be very helpful. Or any link to a howto.
More or less:
mount /target_partition. mount --bind /proc /target_partition/proc mount --bind /sys /target_partition/sys mount --bind /dev /target_partition/dev chroot /target_partition
You might have to edit /target_partition/etc/mtab.
Then, run mkinitrd whatever.
Remember that those directories (proc, sys, dev) in the target should be empty before the binding.
Thanks a lot! I did not know about --bind option. Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Monday, 2010-01-18 at 15:15 -0000, Tejas Guruswamy wrote:
try mkinitrd -s 1024x768 (or whatever resolution you want) - look at man 8 mkinitrd.
I think it should be better to modify /etc/sysconfig/bootloader - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) iEYEARECAAYFAktU9oEACgkQtTMYHG2NR9XbrACdElJapAU/Vvh8z4yy5dG2c1oy X+0An0uaQIvp2RHQXIR4EZrk5m7TyVxh =XTEV -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 2010/01/18 13:38 (GMT+0100) Istvan Gabor composed:
Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one:
"Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)"
The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd.
Why is the root device hardcoded in initrd? How could this hardcoding be prevented?
I successfully cloned one just a few days ago, but I remembered also to regenerate the uuid of the cloned partition. Having more than one root partition with identical UUIDs is not good. On first boot of the clone I did generate new initrds, but for unreleated reasons <http://bugzilla.novell.com/show_bug.cgi?id=483136>, not because I knew if I had to. Grub also needed reinstallation on the clone in order to actually use the menu.lst from the clone. ATM, I don't remember if I had to do anything else. -- "Our Constitution was made only for a moral and religious people. It is wholly inadequate to the government of any other." John Adams, 2nd US President Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://fm.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
2010. január 18. 13:54 napon Felix Miata <mrmazda@earthlink.net> írta:
On 2010/01/18 13:38 (GMT+0100) Istvan Gabor composed:
Recently I had more times boot problems with openSUSE 11.1 and 11.2 after cloning/copying the operating system from one partition to another. Even if I adjusted fstab and boot manager (grub) according to the new location the boot stopped with errors like this one:
"Waiting for device /dev/disk/by-id/ata-MaxtorXXXXXX-part3 to appear. Could not find /dev/disk/by-id/ata-MaxtorXXXXXX-part3 Want me to fallback to /dev/disk/by-id/ata-MaxtorXXXXXX-part3 (y/n)"
The device the message cites hosted the root partition of the system before cloning. It seems that this information is hardcoded in initrd.
Why is the root device hardcoded in initrd? How could this hardcoding be prevented?
I successfully cloned one just a few days ago, but I remembered also to regenerate the uuid of the cloned partition. Having more than one root partition with identical UUIDs is not good. On first boot of the clone I did
Actually it was not the partition what I cloned but the directory system. I created another ext3 filesystem on another partition and used rsync -a command to copy openSUSE 11.2 to the new partition. So I don't have the same UUIDs. I don't use partition labels either.
generate new initrds, but for unreleated reasons , not because I knew if I had to. Grub also needed reinstallation on the clone in order to actually use the menu.lst from the clone. ATM, I don't remember if I had to do anything else.
Yes, I also reinstalled grub after adjusting menu.lst but this did not solve/prevent the issue. The boot process starts normally but it stops since it can not find a device which is not needed at all. The root parameter in menu.lst clearly defines which one is the root disk. Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (6)
-
Carlos E. R.
-
Felix Miata
-
Istvan Gabor
-
Per Jessen
-
Steffen Winterfeldt
-
Tejas Guruswamy