udevadm settle hangs

Bug #387086 reported by Thomas Zehetbauer
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
cryptsetup (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

Binary package hint: udev

I am trying to automatically mount a LUKS volume when I log in:

/etc/security/pam_mount.conf:
<volume path="/dev/sda3" user="tom"/>

/etc/fstab:
/dev/sda3 /media/sda3 crypt defaults,noauto,nodev,nosuid 0 0

Instead of mounting the volume this causes the login process to get stuck:

mount -p0 -o defaults,noauto,nodev,nosuid -t auto /dev/sda3 /media/sda3
/sbin/mount.crypto_LUKS /dev/sda3 /media/sda3 -o rw,nosuid,nodev
cryptsetup luksOpen /dev/sda3 _dev_sda3
sh -c /sbin/udevadm settle
/sbin/udevadm settle

I am currently using chmod 644 /sbin/udevadm as a workaround.

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

Try "udevadm settle --timeout=10"

it may print output after 10s, if so, supply that

Changed in udev (Ubuntu):
status: New → Incomplete
Revision history for this message
Thomas Zehetbauer (realborg) wrote :

I now wrote a wrapper to call "udevadm settle --timeout 30" instead of udevadm.

It still hangs in rt_sigsuspend(~[TRAP KILL SEGV STOP RTMIN RT_1])

Revision history for this message
Patrick Domack (patrickdk) wrote :

I am having the same issue, using lkus dm_crypt mount on user login.
Using ubuntu 9.04 with all updates current as of today.
I made a sample wrapper script also like said above, but it still hangs with the --timeout=10

#!/bin/sh
OPTION=""
if [ "$1" = "settle" ]; then
  OPTION="--timeout=10"
fi
/sbin/udevadm.orig "$@" $OPTION

Revision history for this message
Thomas Zehetbauer (realborg) wrote :

mv /sbin/udevadm /sbin/udevadm.real
cat >/sbin/udevadm <<EOF
#!/bin/sh
if [ "$1" == "settle" ] ; then
    sleep 1
else
    exec /sbin/udevadm.real "$@"
fi
EOF
chmod 755 /sbin/udevadm

Revision history for this message
Christian Iversen (chrivers) wrote :

Why is this bug incomplete? It has all the steps to reproduce, and it can be consistently reproduced.

Revision history for this message
Christian Iversen (chrivers) wrote :

This bug has a proposed patch and a discussion of the problem:

http://thread.gmane.org/gmane.linux.kernel.device-mapper.dm-crypt/2804

Revision history for this message
Christian Iversen (chrivers) wrote :

One last thing. The Gentoo Bugs mailing list has a discussion of the same problem. Several people have reported back that the mentioned patch works fine. No one has reported that it does not work:

http://bugs.gentoo.org/242778

Please consider getting this patch into cryptsetup, as the functionality is currently severely hampered.

affects: udev (Ubuntu) → cryptsetup (Ubuntu)
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for cryptsetup (Ubuntu) because there has been no activity for 60 days.]

Changed in cryptsetup (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.