On Sun, Apr 22, 2007 at 02:37:30 +0200, Thomas Anderson wrote: > Florian Kulzer wrote: > > On Sat, Apr 21, 2007 at 19:54:09 +0200, Thomas Anderson wrote: > > > > [ Earlier attributions were missing, therefore I am not entirely sure > > who said what already. ] > > It's been me and Jay Flory talking so far. > > >>>> In all the above cases I got this line: > >>>> > >>>> "Setting up cryptographic volume sda5_crypt (based on /dev/sda5)" > >>>> before the "Enter LUKS passphrase" line. So even if I changed grubs > >>>> menu.lst according to above, the computer still tries to decrypt my > >>>> root filesystem from sda instead of from sdb. I guess the initrd file > >>>> that comes with Etch needs editing, correct? But what to edit and how? > >>>> I've never changed any initrd file before. > > > > [...] > > > >> My bad. I meant to write root=/dev/sdb1 in my previous mail but > >> accidentally wrote root=/dev/hdb1. When I tried to change grubs > >> menu.lst-file, I wrote root=/dev/sdb1, though. I even tried it once > >> again after you corrected me. But it still would not work. It still wrote: > >> > >> "Setting up cryptographic volume sda5_crypt (based on /dev/sda5)" > >> before the "Enter LUKS passphrase" line. > >> > >> Thanks for trying to help me though. I guess it would have worked if I > >> had not had an encrypted base file system. > > > > If I understand your situation correctly then you need indeed to rebuild > > your intird so that it uses the correct root partition. (It may be > > possible to simply edit the existing initrd to reflect the change, but I > > would not know how to do that. You should keep a backup of the current > > initrd in any case.) > > > > How do you access your system at the moment? Can you boot from a rescue > > CD and mount the encrypted root partition? > > At the moment I remove my other sata hd and then boot my computer with > only the Etch sata hd in. > Before I edit the initrd file I have to find out exactly what in it I > should change to reflect the change. If I find a solution I'll post it here.
I think you can build an additional initrd, test it and make the change permanent if it works. It should be relatively simple since you can build the initrd on the normally booted system, no need to mess around with chroot. Using yaird it should work like this: 1) Edit /etc/yaird/Default.cfg: Comment out the line MOUNTDIR "/" "/mnt" and uncomment the line # MOUNTDEV "/dev/hda3" "/mnt" Change "/dev/hda3" to the right partition for the new situation (/dev/sdb1, I think). 2) Edit the "/" entry in /etc/fstab in the same manner. 3) Build the new initrd: yaird --output=/boot/initrd.img-test 4) Shut down the system and attach the second drive. 5) Start up again, press 'e' to change the grub configuration for "root=" and point initrd to /boot/initrd.img-test. Then press 'b' to boot and keep your fingers crossed. The only thing that I am not sure about is whether it is necessary to revert the /etc/fstab change temporarily to shut the system down cleanly (i.e. after step 3). In that case you would need a rescue disk (or some other means) to change /etc/fstab again before step 5. With a suitable rescue disk at hand the above procedure should be safe since you can keep the old initrd around until you are sure that the new one works. -- Regards, | http://users.icfo.es/Florian.Kulzer Florian | -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]