1 Upstream tracker: https://sourceforge.net/p/lxc/bugs/75/
3 the variables get assigned as:
4 KVER_MAJOR="3\n# Linux VServer"
5 KVER_MINOR="10\n# Linux VServer"
7 which causes parse errors:
9 Cgroup memory controller:
10 + '[' 3 '#' Linux VServer -ge 3 -a 10 '#' Linux VServer -ge 6 ']'
11 /usr/bin/lxc-checkconfig[98]: [: #: unexpected operator/operand
12 + is_enabled CONFIG_CGROUP_MEM_RES_CTLR
15 if [ $KVER_MAJOR -ge 3 -a $KVER_MINOR -ge 6 ]; then
16 is_enabled CONFIG_MEMCG
18 is_enabled CONFIG_CGROUP_MEM_RES_CTLR
23 $ zgrep '^# Linux' /proc/config.gz | sed -r 's/.* ([0-9])\.[0-9]{1,2}\.[0-9]{1,3}.*/\1/'
28 $ zcat /proc/config.gz |grep '^# Linux'
30 # Linux/x86_64 3.10.10 Kernel Configuration
35 --- lxc-0.9.0/src/lxc/lxc-checkconfig.in 2013-09-17 12:00:03.486888314 +0300
36 +++ lxc-0.9.0/lxc-checkconfig 2013-09-17 12:47:12.000000000 +0300
40 CGROUP_MNT_PATH=`print_cgroups cgroup /proc/self/mounts | head -1`
41 -KVER_MAJOR=$($GREP '^# Linux' $CONFIG | \
42 +KVER_MAJOR=$($GREP '^# Linux.*Kernel Configuration' $CONFIG | \
43 sed -r 's/.* ([0-9])\.[0-9]{1,2}\.[0-9]{1,3}.*/\1/')
44 if [ "$KVER_MAJOR" = "2" ]; then
45 -KVER_MINOR=$($GREP '^# Linux' $CONFIG | \
46 +KVER_MINOR=$($GREP '^# Linux.*Kernel Configuration' $CONFIG | \
47 sed -r 's/.* 2.6.([0-9]{2}).*/\1/')
49 -KVER_MINOR=$($GREP '^# Linux' $CONFIG | \
50 +KVER_MINOR=$($GREP '^# Linux.*Kernel Configuration' $CONFIG | \
51 sed -r 's/.* [0-9]\.([0-9]{1,3})\.[0-9]{1,3}.*/\1/')