Systemd: Applying systemd-networkd configuration disconnects all other interfaces

Created on 3 Jun 2017  路  3Comments  路  Source: systemd/systemd

Submission type

  • Bug report
  • Request for enhancement (RFE)

systemd version the issue has been seen with

232-23

Used distribution

Debian 9

In case of bug report: Expected behaviour you didn't see

I'm running a software router with the bird BGP daemon on debian9. There are a lot of interfaces (VLAN, GRE, Ethernet, Wireless).
I was expecting to see a possibility to add / remove / enable / disable a single interface, like ifup / ifdown, or even systemd does for services.

In case of bug report: Unexpected behaviour you saw

When adding an interface, there is no possibility to add just a single interface. It is required to restart systemd-networkd (or even reboot the system, windows-like). Restarting systemd-networkd disconnects all other interfaces (therefore there is packetloss, BGP neighbours will drop, ...).

In case of bug report: Steps to reproduce the problem

Configure a new interface and try to bring it up on the fly with no impact to other interfaces.

duplicate network

Most helpful comment

Yeah, we currently have no API for reloading config or upping/downing interfaces individually. We really should add that. THis is kinda a duplicate of #3031 and is a well-known limitation of networkd, closing this one as duplicate.

All 3 comments

I am not sure I follow. networkd only takes possession of interfaces you are telling it to take possession of. "networkctl status -a" will tell you which interfaces it takes care and which .network file it applies to each...

It appears to me your .network file [Match] section is simply too broad and applies to network interfaces it really shouldn't apply to?

Hi,

no, I match by name, that's not the thing.
The problem is if I have an interface which is already configured by systemd-networkd, let's say eth0, and I'd like to configure another interface (eth1), in order to apply the configuration for eth1, it's necessary to restart the systemd-networkd service. This process brings down ALL interfaces (also the previous configured eth0) and up again. That means, there is an interruption, even on eth0.

There should be a possibility to bring up an interface on-the-fly with no impact to other interfaces (like ifup eth1).

Also, if you'd like to change the configuration of an interface which is already configured by systemd (e.g. IP, Gateway, whatever), you need to restart the whole service (systemctl restart systemd-networkd). As said, this will also bring down all other interfaces (where I didn't change anything). With ifupdown, you have the possibility to restart just a single interface (ifdown ethX && ifup ethX).

Regards
Patrick

Yeah, we currently have no API for reloading config or upping/downing interfaces individually. We really should add that. THis is kinda a duplicate of #3031 and is a well-known limitation of networkd, closing this one as duplicate.

Was this page helpful?
0 / 5 - 0 ratings