[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[linux-lvm] Race condition in udev_is_running check when running under systemd

Hi all,

first of I hope I have come to the right place for reporting (possible)
bugs, if not feel free to give me a gentle kick in the right direction

After updating to systemd-212 I was experiencing problems with
cryptsetup for a while. systemd would open and close my encrypted
partitions in rapid succession, causing dependent services like fsck to
fail most of the time because the device vanished again.

After some discussion on the systemd mailing list and a bit of debugging
I found that the root of the issue is, that when systemd calls cryptsetup
the _check_udev_is_running() function (in ./libdm/libdm-common.c) would
still return false.
This causes libdm to create some device nodes itself, and that in turn
apparently to causes the problems with systemd thinking the device has

According to the systemd developers this issue should be fixed on the
libdm side. To quote the relevant part from the mails there:

>On 15/05/14 23:38, Lennart Poettering wrote:
>> On Thu, 15.05.14 23:15, Andy Kittner (andy kittner gmail com) wrote:
>>> Anyway, my conclusion from this is that either the LVM guys need to
>>> use another method to detect that udev is running, or systemd should
>>> not start the cryptsetup stuff until udev is fully initialized.
>> Nope, we don't need more synchronization. The LVM guys should stop doing
>> mknod() on their own.

For full details see the thread here


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]