aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorReto Gantenbein <reto.gantenbein@linuxmonk.ch>2011-01-18 00:45:17 +0100
committerDaniel Lezcano <dlezcano@fr.ibm.com>2011-01-19 00:29:41 +0100
commitfb4c7e28291f013ae30e21108177556fdff870d1 (patch)
tree95905d38b6f3c09161ea4beb3f7ba1eb29f93cf6
parentOnly bring up network interface if IFF_UP is set (diff)
downloadlxc-fb4c7e28291f013ae30e21108177556fdff870d1.tar.gz
lxc-fb4c7e28291f013ae30e21108177556fdff870d1.tar.bz2
lxc-fb4c7e28291f013ae30e21108177556fdff870d1.zip
Adds correct file capa detection for >2.6.32 The kernel compile parameter was removed with kernel release 2.6.33 Since then file capabilities are enabled by default kernel commit: b3a222e52e4d4be77cc4520a57af1a4a0d8222d1
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
-rwxr-xr-xsrc/lxc/lxc-checkconfig.in6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lxc/lxc-checkconfig.in b/src/lxc/lxc-checkconfig.in
index 7097fef..6ce79f4 100755
--- a/src/lxc/lxc-checkconfig.in
+++ b/src/lxc/lxc-checkconfig.in
@@ -76,8 +76,10 @@ echo -n "Macvlan: " && is_enabled CONFIG_MACVLAN
echo -n "Vlan: " && is_enabled CONFIG_VLAN_8021Q
KVER_MINOR=$($GREP '^# Linux kernel version:' $CONFIG | \
sed -r 's/.*2.6.([0-9]{2}).*/\1/')
-[[ ${KVER_MINOR} < 33 ]] && echo -n "File capabilities: " && is_enabled \
- CONFIG_SECURITY_FILE_CAPABILITIES
+echo -n "File capabilities: " &&
+ [[ ${KVER_MINOR} < 33 ]] && is_enabled CONFIG_SECURITY_FILE_CAPABILITIES ||
+ [[ ${KVER_MINOR} > 32 ]] && $SETCOLOR_SUCCESS && echo -e "enabled" &&
+ $SETCOLOR_NORMAL
echo
echo "Note : Before booting a new kernel, you can check its configuration"