Search code examples
linuxubuntucentos

Does systemctl daemon-reload need to be executed using root/sudo?


Does systemctl daemon-reload need to be executed using root/sudo? and does the same command apply to both Centos 7 and Ubuntu 18.04.3 LTS?


Solution

  • $ systemctl daemon-reload
    
    ==== AUTHENTICATING FOR org.freedesktop.systemd1.reload-daemon ====
    Authentication is required to reload the systemd state.
    Authenticating as: neo
    Password:
    

    Yeah, I'd say so. Unless you are doing it in a container with root privileges, pretty sure you need to have root permissions for anything related to systemd services.