Commit 88d413d5 by Sven Wegener Committed by Daniel Lezcano

Add relatime and strictatime mount options

Also add #ifndef for compability with glibc before 2.12. Signed-off-by: 's avatarSven Wegener <sven.wegener@stealer.net> Signed-off-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com>
parent 820339bd
...@@ -80,6 +80,14 @@ lxc_log_define(lxc_conf, lxc); ...@@ -80,6 +80,14 @@ lxc_log_define(lxc_conf, lxc);
#define MNT_DETACH 2 #define MNT_DETACH 2
#endif #endif
#ifndef MS_RELATIME
#define MS_RELATIME (1 << 21)
#endif
#ifndef MS_STRICTATIME
#define MS_STRICTATIME (1 << 24)
#endif
#ifndef CAP_SETFCAP #ifndef CAP_SETFCAP
#define CAP_SETFCAP 31 #define CAP_SETFCAP 31
#endif #endif
...@@ -147,6 +155,10 @@ static struct mount_opt mount_opt[] = { ...@@ -147,6 +155,10 @@ static struct mount_opt mount_opt[] = {
{ "nodiratime", 0, MS_NODIRATIME }, { "nodiratime", 0, MS_NODIRATIME },
{ "bind", 0, MS_BIND }, { "bind", 0, MS_BIND },
{ "rbind", 0, MS_BIND|MS_REC }, { "rbind", 0, MS_BIND|MS_REC },
{ "relatime", 0, MS_RELATIME },
{ "norelatime", 1, MS_RELATIME },
{ "strictatime", 0, MS_STRICTATIME },
{ "nostrictatime", 1, MS_STRICTATIME },
{ NULL, 0, 0 }, { NULL, 0, 0 },
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment