encrypted root initialisation races/fails on hotplug devices (does not wait)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
initramfs-tools (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
I installed ubuntu 8.0.4 to a USB flash drive. I have a volume group that contains encrypted root and swap logical volumes. On some machines the USB drive appears later than initramfs:
As a hack I put in a 10 seconds delay:
*** scripts/
--- scripts/
***************
*** 271,274 ****
--- 271,275 ----
# Do we have any settings from the /conf/conf.
if [ -r /conf/conf.
+ sleep 10
while read mapping; do
This is only temporary, a better solution could be to wait in activate_vg for the device to appear before setting up the volume group, just like https:/
If you can provide a patch that is better than this I could try it out. I will be offline for 3 weeks.
Changed in initramfs-tools: | |
status: | New → Confirmed |
After reading my report I noticed that I was not quite clear on how I set up the system. d/cryptroot in initramfs:
Here is my /conf/conf.
target= sdc5_crypt, source= /dev/disk/ by-uuid/ 139c41d5- 3699-4032- a827-3e9fc45aac 7a,key= none,lvm= UUID=eecf28c6- 9f0c-46f1- a8b4-14268677c4 c4 sdc5_crypt, source= /dev/disk/ by-uuid/ 139c41d5- 3699-4032- a827-3e9fc45aac 7a,key= none,lvm= gaspar- swap
target=
/dev/disk/ by-uuid/ 139c41d5- 3699-4032- a827-3e9fc45aac 7a is the disk that is slow to appear.