You are not logged in.
Hi there,
since I've replaced my old laptop HDD with a new Corsair Force Series GT SSD, I have to use an external HDD for my music, videos etc. (WD MyBook 1140). On my external HDD there's now an encrypted partition which I'd like to mount while Arch Linux boots. However, it seems like UDev is too slow while creating the respective device node, because cryptsetup is unable to open the encrypted device:
Sun Mar 11 23:40:09 2012: :: Starting UDev Daemon [BUSY] [DONE]
Sun Mar 11 23:40:09 2012: :: Triggering UDev uevents [BUSY] [DONE]
Sun Mar 11 23:40:09 2012: :: Loading User-specified Modules [BUSY] [DONE]
Sun Mar 11 23:40:09 2012: :: Waiting for UDev uevents to be processed [BUSY] [DONE]
Sun Mar 11 23:40:09 2012: :: Bringing up loopback interface [BUSY] [DONE]
Sun Mar 11 23:40:09 2012: :: Unlocking encrypted volumes: [BUSY] ^[[udata..Device /dev/disk/by-uuid/3342f8e7-d085-4699-bcf3-253e8e84af5a doesn
However, if I do ls /dev/disk/by-uuid when everything is set up, the device node (3342f8e7-d085-4699-bcf3-253e8e84af5a) exists ...
Config files:
tmpfs /tmp tmpfs nodev,nosuid 0 0
UUID=5b4b7306-c13d-406e-ac93-796f37571e36 /boot ext2 defaults,relatime 0 1
UUID=5be7ac11-26a3-490f-85ad-31876a3b9466 / btrfs defaults,ssd,relatime,discard 0 1
#/dev/mapper/data /home/weegee/data ext3 defaults,user_xattr 0 2
(last entry is commented out since Arch Linux won't boot if there's no /dev/mapper/data)
data /dev/disk/by-uuid/3342f8e7-d085-4699-bcf3-253e8e84af5a "<my password here>"
I hope there is a solution for this :3
Last edited by Weegee (2012-03-12 13:34:03)
~
Offline
Just a clarification:
Udev does not create any device nodes (any more). It is all done by the kernel. However, you are right that this is probably udev related, as "Waiting for UDev uevents to be processed" (i.e. "udeadm settle") should block until the kernel has finished creating all the devices (and udev has created all the symlinks in /dev/disk/by-*).
Offline
falconindy just pointed out to me that i missed the point of your post I thought the problem was with an SSD drive, but the issue is with an external (probably usb?) drive.
This is a known issue, with no really good solution within the confines of sysvinit. The problem is the way usb drives are enumerated. It means that we never know when all the usb drives have been detected (unlike ata drives), and "udevadm settle" does not (can not) wait for them.
The only real solution here is to move to an event-driven model for init (such as upstart or systemd), where this kind of thing would not be a problem (they do not wait for "udevadm settle" before mounting (or setting up encryption for that matter), rather they mount the drives in your fstab as they become available).
A workaround might be to add a initsrcipts hook to sysinit_udevsettled that just waits for a few seconds (a bit of trial and error is probably needed to find the right amount of time it takes for your usb devices to be set up).
Offline
Sorry if it was unclear However, now I'm using systemd, and everything seems to work (except some cryptsetup-related problems, but that's a different story ...)
Thanks!
~
Offline