Commit 8876026d authored by intrigeri's avatar intrigeri

Use `systemctl mask' instead of manually symlinking, and thus avoid unneeded daemon-reload.

`systemctl daemon-reload' is a very big hammer: while it's running, socket
activation, D-Bus activation, and more systemd functionality are disabled.
In this case, as long as we use only systemctl {stop, disable, mask}, then we
don't need to do a global daemon reload, so let's not take the risk.
parent d47825a8
......@@ -23,9 +23,8 @@ stop_and_disable_NM() {
NetworkManager.service; do
systemctl stop "${s}"
systemctl disable "${s}"
ln -s /dev/null "/etc/systemd/system/${s}"
systemctl mask "${s}"
done
systemctl daemon-reload
log "Networking disabled"
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment