[SOLVED] Cannot start LXC container due to /sbin/init permission denied

genguser

Member
Mar 5, 2021
8
2
8
125
Hi,

i had problem with starting some LXC containers. Some did work some not.
From lxc-start debug log i saw this:

ERROR start - ../src/lxc/start.c:start:2164 - Permission denied - Failed to exec "/sbin/init" ERROR sync - ../src/lxc/sync.c:sync_wait:34 - An error occurred in another process (expected sequence number 7) ERROR start - ../src/lxc/start.c:__lxc_start:2074 - Failed to spawn container "121" ERROR lxc_start - ../src/lxc/tools/lxc_start.c:main:306 - The container failed to start ERROR lxc_start - ../src/lxc/tools/lxc_start.c:main:311 - Additional information can be obtained by setting the --logfile and --logpriority options

Problem was in zfs exec parameter which was inherited from parent where i had set manually exec=off. That affects even new created LXC containers datasets. I think that's how zfs works and cannot be changed imo.
I just wanted to share that if somebody has similar issue.

Thanks.
 
  • Like
Reactions: Matthias.