I want to run LXC 2.0 on linux kernel 2.6.38 and init.d, whether both kernel version and initd are mandatory.
I have recompiled the Kernel with namespace support as follow.
# Kernel parameters
CONFIG_NAMESPACES=y
CONFIG_CGROUP_NS=y
CONFIG_UTS_NS=y
CONFIG_IPC_NS=y
CONFIG_USER_NS=y
CONFIG_PID_NS=y
CONFIG_NET_NS=y
[root@ts ~]# CONFIG=$(pwd)/.config lxc-checkconfig
--- Namespaces ---
Namespaces: enabled
Utsname namespace: enabled
Ipc namespace: enabled
Pid namespace: enabled
User namespace: enabled
newuidmap is not installed
newgidmap is not installed
Network namespace: enabled
Multiple /dev/pts instances: enabled
--- Control groups ---
Cgroup: enabled
Cgroup clone_children flag: enabled
Cgroup device: missing
Cgroup sched: enabled
Cgroup cpu account: enabled
Cgroup memory controller: enabled
Cgroup cpuset: enabled
Everything runs successful until I hit the following issue on lxc-start -n ts1 --logfile=ts1.log
.
lxc_start - start.c:preserve_ns:138 - No such file or directory - Kernel does not support attaching to namespaces.
LXC/start.c:138 says that my parent process does not have /proc/<PID>/ns
folder and when I check it was true even for all processes in the system including initd.
I assume that initd does not take namespaces into account as initial process.
What I need to do in order to get initd attached with namespace?