On Fri, 27.12.13 10:18, Michael Olbrich (m.olbr...@pengutronix.de) wrote:

> Currently adding directories to ReadWriteDirectories= only restores the
> original mount flags. So e.g. setting ReadOnlyDirectories=/usr and
> ReadWriteDirectories=/usr/local works as expected if the underlying file
> system was writable. However, setting ReadWriteDirectories= has no effect
> if the underlying file system is mounted read-only.
> This patch changes that by explicitly remounting the bind mount.

Hmm, so, if the underlying fs is read-only we shouldn't really change
that...

However, it should be possible to simply mount the root mount point
read-only while leaving the backing fs writable. or in other words,
there's a difference between "mount / -o rw,remount" and "mount --bind /
-o rw,remount". The fprmer changes the file system itself, the latter
only the mount point. 

Unfortunately you cannot make this happen with pure fstab, so, you need
to manually invoke that from some service during boot. 

Lennart

-- 
Lennart Poettering, Red Hat
_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to