CentOS recent issues ? System has not been booted with systemd as init system (PID 1). Can't operate

I’ve had some containers running in lxd on Centos for nearly a year, not sure whats happend recently but now I can’t run anything

When running systemctl inside the container I get:
System has not been booted with systemd as init system (PID 1). Can't operate.

Just wondering if anyone else has noticed this. Not sure if its a selinux issue?

lxc console NAME --show-log may be helpful there

Hi!
Looking more like permissions of sorts, I think it maybe some corporate lockdown enabled on this specific centos server

root@netflow-01:~# lxc console haproxy --show-log

Console log:

Failed to mount cgroup at /sys/fs/cgroup/systemd: Operation not permitted
[!!!!!!] Failed to mount API filesystems, freezing.
Freezing execution.

Interesting how docker works though.

Ok, so that means that you don’t have a name=systemd cgroup mount on the host, this then breaks systemd in containers as the kernel won’t allow the mount.

That’s odd because CentOS 7 uses systemd I thought, so you’d expect the host to have properly setup systemd cgroups.

Can you show grep cgroup /proc/self/mountinfo on the host?

Think we can close this off as I i’m running this particular instance on severely locked down CentOS VM, they probably pushed something out with Puppet. Not a rabbit hole worth diving down.
Thanks for your help!
Cheers,
Jon.:grin: