systemd unit ExecStop runs after network has finished, but requires network to stop
Issue
- systemd unit ExecStop runs after network has finished, but requires network to stop
- systemd unit contains
Requires=network.target
andAfter=network.target
but NetworkManager Team network interface stops before the systemd unit stops. When using Ethernet or Bond network interface, the service stops fully before the network is down - What needs to be put in a systemd service file in order that the ExecStop script gets executed completely before the network is shut down?
Environment
- Red Hat Enterprise Linux 7.1
- NetworkManager running Team network interface
- systemd service unit file whose
ExecStop
requires network connectivity to properly shut down
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.