[systemd-devel] systemd kills mdmon if it was started manually by user
NeilBrown
neilb at suse.de
Sun Nov 6 20:30:37 PST 2011
On Mon, 7 Nov 2011 04:42:54 +0100 Kay Sievers <kay.sievers at vrfy.org> wrote:
> On Mon, Nov 7, 2011 at 03:52, NeilBrown <neilb at suse.de> wrote:
>
> > However there is an important piece missing. When you remount,ro a
> > filesystem, the block device doesn't get told so it thinks it is still open
> > read/write. So md cannot tell mdmon that the array is now read-only
>
> That ro/rw flag is visible in /proc/self/mountinfo, shouldn't it be
> possible for mdmon to poll() that file and let the kernel wake stuff
> up when the ro/rw flag changes, like we do for the usual mount changes
> already?
>
> Kay
The ro/rw flag for file systems is in /proc/self/mountinfo.
However I want the ro/rw flag for the block device.
A block device can be partitioned so it might have multiple filesystems on it.
and it might have swap too.
or a dm table or another md device or an open file descriptor or ....
Yes, I could maybe parse various different files and try to work out what is
going on. But the kernel can easily *know* what is going on.
Making this work "perfectly" would require md dropping its write-access to
member devices when the last write-access to the top level device goes. And
the same for dm and loop and .....
But just filesystems would go a long way to catching the common cases
correctly.
Thanks,
NeilBrown
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 828 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/systemd-devel/attachments/20111107/4e46cf44/attachment.pgp>
More information about the systemd-devel
mailing list