Alpine linux lxc container don' start, "ABORTING "instead of "RUNNING"

I successfully can start ubuntu privileged lxc containers on my debian 11 host but after creating alpine instances i get error messages :
I create container via:
lxc-create -t download - n name1
And get the result a created conatiner
I picked alpine 3.16 amd64 but have tried edge releases as well.
lxc-start -n name1 results in
I get error messades lxccontainer.c: wait_on daemonized start:859 Received container state “ABORTING” instead of “RUNNING”
Something with apparmor perhaps?
I have tried setting STP interface on but no change.
I tried to run apparmor_parser command before starting container but that command just hangs.

Anybody have ideas of what to do? can I do modifications of alpine rootfs image before starting?

You’ll want to start with something like lxc-start -F -n name1 -l debug to know more about what’s going on.

Thanks, I suspect maybe I have to little memory for the alpine container. Maybe I need to somehow assign memory by creating a file /etc/usenet.

(I have no other container running simultaneously though)

lxc-start -F -n name1 -l debug:

lxc-start:name1:sync.c: __sync_wait:36 An error occurred in another process(expected sequence number 7)
lxc-start:name1::start.c __lxc_start:1999 Failed to spawn container "name1"
tail /var/log/kern.log:

[4413.779390] lxbr0: port 1(veth2CGvx) entered blocking state
[4413.779394] lxbr0: port 1(veth2CGvx) entered forwarding state
[4413.850039] Not activating Manadatory Access control as /sbin/tomoyo-init does not exist.
[5116.039952] audit:type=1400 audit(1708859227.179:27):apparmor="STATUS" operation="profile_remove" profile="/usr/bin/lxc-start" name="lxc-name1_</var/lib/lxc>" pid=1478 comm="apparmor_parser"
[5116.08008] lxcbr0: port 1(veth2CGvx) entered disable
lxc-start --version


Hmm, try adding -o debug too and then look at the content of the debug file it will write out.

At the top of the debug file another error message appears:
lxc-start name1 ERROR start -start.c:start 2090- Exec format error-Failed to exec "/sbin/init"

I noticed that the ubuntu containers that all start and work has fstab content:
while the alpine container that will not start has fstab

/dev/cdrom  /media/cdrom  iso9660 noauto,ro 0 0
 /dev/usbdisk/  /media/usb  vfat         noauto,ro 0 0

I see some google results might indicate something with zfs filesystems must be mounted with exec=on
although a bit unclear to me if there is somewhere to configure that.


Hmm, that error sounds like you have a container of the wrong architecture maybe?

What does sudo file /var/lib/lxc/name1/rootfs/sbin/init show you?

Thankyou, Yeah, I have picked wrong architecture for my containers.
Alpine container that not works:

file /var/lib/lxc/name1/rootfs/sbin/init:
/var/lib/lxc/name1/rootfs/sbin/init: symbolic link to /bin/busybox

For the working ubuntu container:

file /var/lib/lxc/ubuntucontainer/rootfs/sbin/init:
/var/lib/lxc/ubuntucontainer/rootfs/sbin/init: symbolic link to /lib/systemd/systemd

(Ubuntu container works somehow anyway with downloaded amd64 image)

As a workaround I deleted the content inside alpine rootfs , and then grabbed the x86 minirootfs from their alpine download site,put it into name1’s rootfs folde,extracted it,and then I could do
lxc-start - n name1 and lxc-attach -n name1.
Networking I configured manually afterwards.
So now all works.