sailfish-containers / lxc-templates-desktop

LXC templates adapted to SailfishOS
GNU Lesser General Public License v2.1
9 stars 2 forks source link

Starting the container on the Nexus 5 (hammerhead) #5

Open edp17 opened 4 years ago

edp17 commented 4 years ago

On the device, the container starts but few seconds later it stops. It gives the following error:

lxc-start Debian 20200729102823.579 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/systemd rw,nosuid,nodev,noexec,relatime master:8 - cgroup cgroup rw,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd
"
lxc-start Debian 20200729102823.579 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/devices rw,nosuid,nodev,noexec,relatime master:11 - cgroup cgroup rw,devices
"
lxc-start Debian 20200729102823.579 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/cpu,cpuacct rw,nosuid,nodev,noexec,relatime master:12 - cgroup cgroup rw,cpuacct,cpu
"
lxc-start Debian 20200729102823.579 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/freezer rw,nosuid,nodev,noexec,relatime master:13 - cgroup cgroup rw,freezer
"
lxc-start Debian 20200729102823.579 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/debug rw,nosuid,nodev,noexec,relatime master:14 - cgroup cgroup rw,debug
"
lxc-start Debian 20200729102823.580 ERROR    lxc_cgfsng - cgroups/cgfsng.c:cg_hybrid_get_controllers:738 - Found hierarchy not under /sys/fs/cgroup: "/opt/alien/sys/fs/cgroup/cpuset rw,nosuid,nodev,noexec,relatime master:15 - cgroup cgroup rw,cpuset
"

Are there any missing kernel requirements?

r3vn commented 4 years ago

i'm not sure if this is due to kernel requirements, is there anything missing on lxc-checkconfig ?

edp17 commented 4 years ago

Nothing is red, only some yellows, but I am not sure which is necessary and which one only optional:

--- 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 --- Cgroups: enabled

Cgroup v1 mount points: /sys/fs/cgroup/systemd /sys/fs/cgroup/devices /sys/fs/cgroup/cpu,cpuacct /sys/fs/cgroup/freezer /sys/fs/cgroup/debug /sys/fs/cgroup/cpuset /opt/alien/sys/fs/cgroup/systemd /opt/alien/sys/fs/cgroup/devices /opt/alien/sys/fs/cgroup/cpu,cpuacct /opt/alien/sys/fs/cgroup/freezer /opt/alien/sys/fs/cgroup/debug /opt/alien/sys/fs/cgroup/cpuset

Cgroup v2 mount points:

Cgroup v1 clone_children flag: enabled Cgroup device: enabled Cgroup sched: enabled Cgroup cpu account: enabled Cgroup memory controller: missing Cgroup cpuset: enabled

--- Misc --- Veth pair device: missing Macvlan: missing Vlan: missing Bridges: enabled, not loaded Advanced netfilter: enabled, not loaded CONFIG_NF_NAT_IPV4: missing CONFIG_NF_NAT_IPV6: missing CONFIG_IP_NF_TARGET_MASQUERADE: enabled, not loaded CONFIG_IP6_NF_TARGET_MASQUERADE: missing CONFIG_NETFILTER_XT_TARGET_CHECKSUM: missing CONFIG_NETFILTER_XT_MATCH_COMMENT: enabled, not loaded FUSE (for use with lxcfs): enabled, not loaded

--- Checkpoint/Restore --- checkpoint restore: missing CONFIG_FHANDLE: enabled CONFIG_EVENTFD: enabled CONFIG_EPOLL: enabled CONFIG_UNIX_DIAG: missing CONFIG_INET_DIAG: enabled CONFIG_PACKET_DIAG: missing CONFIG_NETLINK_DIAG: missing File capabilities:

Note : Before booting a new kernel, you can check its configuration usage : CONFIG=/path/to/config /usr/bin/lxc-checkconfig

edp17 commented 4 years ago

I have compared the lxc-checkconfig on the Nexus 5 (hammerhead) and the Note 4 (treltexx) and I spotted that this was missing on the Nexus 5: CONFIG_NF_NAT_IPV4 Both of them supported in kernels: 3.7–3.19, 4.0–4.20, 5.0 The Nexus 5 has a kernel 3.4, so if this is required, then it will not work on the Nexus 5 as there is no kernel support for that. :(

r3vn commented 4 years ago

According to linuxcontainers.org "Linux kernel >= 3.8" is an extra requirement for lxc-attach,i'm not sure but you might be able to start a container and access it using ssh. I see some "/opt/alien/.." on your log file, did you try to start the container while AD is turned off?

G.

Kabouik commented 4 years ago

Does AD install on Nexus 5? I thought the Pro¹ was an exception in that regard thanks to its SoC similar to some official devices' SoCs.

On 2020-08-02 04:24 Giuseppe Corti notifications@github.com wrote:

According to linuxcontainers.org "Linux kernel >= 3.8" is an extra requirement for lxc-attach,i'm not sure but you might be able to start a container and access it using ssh. I see some "/opt/alien/.." on your log file, did you try to start the container while AD is turned off?

G.

--
You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/sailfish-containers/lxc-templates-desktop/issues/5#issuecomment-667614573

edp17 commented 4 years ago

According to linuxcontainers.org "Linux kernel >= 3.8" is an extra requirement for lxc-attach,i'm not sure but you might be able to start a container and access it using ssh. I see some "/opt/alien/.." on your log file, did you try to start the container while AD is turned off?

The main problem is when I start the container, after a few seconds it stops. I don't know how to force it to stay running. As it stops, the attach doesn't work either. I was trying to start the container while the AD was up and running on the device.

Edit: I've tried to start the container with AD stopped, but the same happened; after a few seconds the container stopped. :(

Edit2: I have tried the instructions on the linuxcontainer.org, but that didn't help. (I installed libseccomp, python3-devel and libgnutls but this didn't help either.)

edp17 commented 4 years ago

Does AD install on Nexus 5? I thought the Pro¹ was an exception in that regard thanks to its SoC similar to some official devices' SoCs.

Yes, AD installs and works on the Nexus 5. However, this AD is not the official one.