From: Nikolaus Rath <Nikolaus@rath.org>
To: linux-lvm@redhat.com
Subject: [linux-lvm] Changing owner of lv device with udev
Date: Wed, 19 Dec 2012 14:41:54 -0800 [thread overview]
Message-ID: <50D242B2.8080108@rath.org> (raw)
Hello,
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:
SUBSYSTEM=="block",
ENV{DM_UUID}=="LVM-yYuoI8k05GWxZnz9BeEIwPUGGeojzF3dZZmXTYRqC051Tllj76OHdDlzYhKZUu7u",
OWNER="1000"
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?
Thanks,
-Nikolaus
next reply other threads:[~2012-12-19 22:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-19 22:41 Nikolaus Rath [this message]
2012-12-20 10:14 ` [linux-lvm] Changing owner of lv device with udev Alasdair G Kergon
2012-12-20 16:36 ` Nikolaus Rath
2012-12-28 6:13 ` Nikolaus Rath
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50D242B2.8080108@rath.org \
--to=nikolaus@rath.org \
--cc=linux-lvm@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).