custom initramfs: switch_root woes
ctlink at binaryelysium.com
ctlink at binaryelysium.com
Tue Apr 10 00:59:31 UTC 2007
I'm implementing the dm-crypt w/ Luks disk encryption solution as
outlined in this wiki entry
http://gentoo-wiki.com/SECURITY_System_Encryption_DM-Crypt_with_LUKS.
The unlocking and mounting is working fine, however when I get to the
bit where I need to switch_root and execute the init that exists on my
disk my system just sorta.. does nothing.
I enabled debugging (-x) for /bin/ash and this is the output at the
time it needs to switch:
+ exec switch_root /new-root /sbin/init
*crickets chirp*
I thought it might be my /etc/conf.d/cryptfs or fstab, but those are
both correct.
It simply freezes after switch_root'ing... the cursor still blinks, I
can make new lines, and a few keys work. But Ctrl+z or c does nothing.
ctrl+alt+del doesn't reset it. Alt+F#s doesn't change anything. My
only option is to perform a hard reboot. I've verified that the root
system is actually mounted in /new-root and /sbin/init exists
(/new-root/sbin/init) with correct permissions.
I've tried busybox versions 1.2.2.1, 1.1.2 and 1.5.0.
When I try and pass /dev/console I get:
exec switch_root -c /dev/console /new-root /sbin/init
switch_root: Bad console '/dev/console'
Kernel Panic - not syncing: Attempted to kill init!
Some debugging has revealed that there is indeed a /dev/console
however there is no /new-root/dev/console.
I'd be glad to post the init script, or any conf files. Anyone know
what might be going on?
More information about the busybox
mailing list