]> git.ipfire.org Git - thirdparty/lxc.git/commit
lxc to apply mount options for bind mounts
authorCiprian Dorin, Craciun <ciprian@volution.ro>
Thu, 24 Jun 2010 07:47:14 +0000 (09:47 +0200)
committerDaniel Lezcano <dlezcano@fr.ibm.com>
Thu, 24 Jun 2010 07:47:14 +0000 (09:47 +0200)
commite76b8764fa0aa1873724a9e4a8a3ca93c0e5cd70
treefabf01b13c2f008d8bd7dccd049e52bd6ff81a60
parenta7dff83460f259c934da8eb2aef0eac5b437b808
lxc to apply mount options for bind mounts

Hello all!

    This bug stalked me for a while, but only now it bit me quite
badly... (Lost about an hour of work...)

    So the culprit: inside the fstab file for the `lxc.mount` option I
can use options like `ro` together with `bind`. Unfortunately the
kernel just laughs in my face and ignores any options I've put in
there... :) But not any more: I've updated `./src/lxc/conf.c`
(`mount_file_entries` function) so that when it encounters a `bind`
option it executes it twice (one without any extra options, and a
second time with the remount flag set.)

I've marginally (as in my particular case) tested it and it works.

Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
src/lxc/conf.c