Change service settings with an override
modify service file without losing it on update | create systemd override | increase limitnofile for a service | make service restart automatically | systemctl | override | configurationCaution: This command changes the system. Understand what it does before you run it.
systemctl edit mariadbCreates /etc/systemd/system/<unit>.d/override.conf and opens it in the editor. Values entered there, for example [Service] with LimitNOFILE=65535 or Restart=on-failure, override the original file and survive package updates. After saving, systemd reloads the configuration automatically, but the service itself still needs to be restarted.
Note: List settings like ExecStart= must first be reset in the override with an empty ExecStart= line. The editor is determined by the SYSTEMD_EDITOR or EDITOR variable.
Also searched as
- modify service file without losing it on update
- create systemd override
- increase limitnofile for a service
- make service restart automatically