systemd 244.1 breaks networking in LXC

moonman

Active Member
Aug 11, 2019
30
19
28
Canada
Hi everyone,

Just thought I would let everyone know that upgrading systemd to 244.1 will break networking if running in LXC container.
Found out the hard way and I'm probably one of the first ones since I'm running ArchLinux in LXC and systemd just got bumped up to 244.1.

Looking at systemd github there are quite a few networking changes between 244 and 244.1 https://github.com/systemd/systemd-stable/commits/v244-stable

Removing and adding network interface for the container in PVE interface for this container will get networking working again, until the container is restarted. I have not tried using something other than systemd-networkd.

EDIT: The solution:
Add lxc.mount.auto: sys to /etc/pve/lxc/<id>.conf
 
Last edited:
hi,

are you running privileged or unprivileged container?
 
same issue here. my arch linux network was broken
privileged containers are not affected
 
I'm using Arch as containers and problem solved by:
yay -U /var/cache/pacman/pkg/systemd-libs-244-1-x86\_64.pkg.tar.xz /var/cache/pacman/pkg/systemd-244-1-x86\_64.pkg.tar.xz
 
I'm using Arch as containers and problem solved by:
yay -U /var/cache/pacman/pkg/systemd-libs-244-1-x86\_64.pkg.tar.xz /var/cache/pacman/pkg/systemd-244-1-x86\_64.pkg.tar.xz
Well, everyone already knew that. yay is not the standard package manager. There is also https://archive.archlinux.org/ in case cache was cleared.
However, downgrading systemd packages is not a good long term solution.
 
Tried more templates:

Fedora 30 does not work out of the box. Systemd v241-8.git9ef65cb.fc30
Fedora 31 works at first, stops after upgrading systemd to 243.5-1 it stops working. Working version is 243-4
Ubutnu 18.04 works. Systemd version 237

There must be a patch that's being backported to other versions and it is causing issues.
 
  • Like
Reactions: Qian Chen
@moonman I'm surprised no one else seems to be complaining this issue, not even anyone is talking about it. Are we the only two users of LXC on the whole internet? This in my opinion should be a major issue and everyone should jump and shout, I expected.
 
@moonman I'm surprised no one else seems to be complaining this issue, not even anyone is talking about it. Are we the only two users of LXC on the whole internet? This in my opinion should be a major issue and everyone should jump and shout, I expected.
My guess is that most LXC users run debian or some derivative that doesn't (yet) have this issue. Possibly CentOS which is very conservative with updates. The rest is not popular.

I'm sure someone is looking into this, it just takes time and it is the holiday season.
There is a workaround for now. Worse comes to worst I'll have to bisect commits between 244 - 244.1.
 
@Elgs Qian Chen, thanks for opening the bug report upstream.
https://github.com/systemd/systemd/issues/14431

If anyone else experiences this, than please add your findings to the upstream bug report. Thanks.

EDIT: added lxc.mount.auto: sys to the CT config. It appears to work with the mixed mount mode of /sys.
 
Last edited:
Before that, sys was in RW mode.

Hi, I think you meant to say that /sas was ro before that and now it will be rw.

From what I can tell, you can continue to use /sys:ro and the functionality is working as expected without the risk of a writable /sys
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!