I have a command I need to run on start up but it requires I enter the password several times and I have no idea how to make this work:
$ systemctl disable systemd-timesyncd && systemctl stop systemd-timesyncd && systemctl enable ntpd && systemctl start ntpd
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-unit-files ===
Authentication is required to manage system service or unit files.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
Removed /etc/systemd/system/sysinit.target.wants/systemd-timesyncd.service.
==== AUTHENTICATING FOR org.freedesktop.systemd1.reload-daemon ===
Authentication is required to reload the systemd state.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
Authentication is required to stop 'systemd-timesyncd.service'.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-unit-files ===
Authentication is required to manage system service or unit files.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
==== AUTHENTICATING FOR org.freedesktop.systemd1.reload-daemon ===
Authentication is required to reload the systemd state.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
Authentication is required to start 'ntpd.service'.
Authenticating as: benja
Password:
==== AUTHENTICATION COMPLETE ===
Is this possible? Any suggestions would be greatly appreciated.