ubuntu:systemd:conflicting_services
This is an old revision of the document!
Ubuntu - SystemD - Conflicting Services
When two services should not run at the same time, you can use the Conflicts parameter.
For example, to stop a VPN running when using the Transmission service.
Edit the transmission-daemon.service.
sudo vi /lib/systemd/system/transmission-daemon.service
…add the following line in the [Unit] section:
Conflicts=vpn.service
NOTE: vpn.service could be a service that starts a VPN connection.
- This means that if I start the transmission-daemon.service, vpnservice will be automatically shut down, and vice versa.
Reload systemd
Reload systemd for the changes to take effect.
sudo systemctl daemon-reload
ubuntu/systemd/conflicting_services.1685787449.txt.gz · Last modified: 2023/06/03 10:17 by peter