[linux-lvm] Changing owner of lv device with udev

Nikolaus Rath Nikolaus at rath.org
Wed Dec 19 22:41:54 UTC 2012


I'm having some trouble changing the owner of a logical device. I added
the following udev rule to both my initramfs and the real root:


If I disable and re-enable this logical volume with lvchange, it gets
created with the correct owner.

However, when I boot the computer, the device always ends up being owned
by root:disk instead.

On the other hand, if I look at the permissions right before initramfs
executes the real init, the permissions are actually correct.

So, at some point between execution of the real init and completed
startup, something overwrites the owner of by device, but both before
and afterward the rule gets applied correctly.

I first blamed this on udev
(http://article.gmane.org/gmane.comp.sysutils.systemd.devel/7605), but I
was told that the problem might be with the special way that LVM uses
udev rules.

Does anyone have an idea what's happening here? How can I get this to work?


More information about the linux-lvm mailing list