FS#30271 - [mkinitcpio] Hang on shutdown

Attached to Project: Arch Linux
Opened by Andreas Messer (amesser) - Tuesday, 12 June 2012, 19:52 GMT
Last edited by Dave Reisner (falconindy) - Thursday, 14 June 2012, 21:00 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Dave Reisner (falconindy)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
In 19 of 20 cases by systems gets stuck on shutdown while the shutdown
script disassembles my lvm logical volumes. The command lvm vgchange...
seems to wait infinitely for something. Maybe its related to using an
logical volume for root filesystem together with using systemd. On shutdown,
systemd tries to deactivate all logical volumes, which of course is
not possible because of the root file system beeing an logical volume too.
In turn, systemd says 'Trying to kill remaining processes' - possibly
terminating udev. Finally systemd gives up and the shutdown script is
executed. Now the 'lvm vgchange' command seems to wait for some udev
actions...
I was able to fix this problem by adding '--noudevsync' to 'lvm vgchange'
in the shutdown script

Additional info:
* mkinitcpio 0.9.2-1

Steps to reproduce:
1) Shutdown
This task depends upon

Closed by  Dave Reisner (falconindy)
Thursday, 14 June 2012, 21:00 GMT
Reason for closing:  Fixed
Additional comments about closing:  mkinitcpio-0.9.2-2

This only fixes vgchange. crypto needs to be dealt with by systemd in a larger way.
Comment by Dave Reisner (falconindy) - Tuesday, 12 June 2012, 20:07 GMT
Neat. I had noticed this as well on my VMs and hadn't taken the time to look into it too much.
Comment by Dave Reisner (falconindy) - Wednesday, 13 June 2012, 01:25 GMT
Hmmm, so this only seems to be half of my problem. shutdown actually hangs on a semaphore while calling 'cryptsetup remove'.

Mail sent upstream about that: http://lists.freedesktop.org/archives/systemd-devel/2012-June/005440.html

Regardless, I'll apply your fix to my local branch, it's clearly the right thing to be doing here.
Comment by Andreas Messer (amesser) - Thursday, 14 June 2012, 18:45 GMT
Thx!

Loading...