1.7 Using the DNF Automatic Tool to Keep Your System Up To Date

The DNF Automatic tool is provided as an additional package that you can use as an alternative to manually running dnf upgrade to keep your system up to date with the latest security patches and bug fixes. The tool can provide automatic notifications of updates, download updates, and then install them automatically by using systemd timers.

You can install the dnf-automatic package and enable the systemd dnf-automatic.timer timer unit to start using this service:

# dnf install dnf-automatic
# systemctl enable --now dnf-automatic.timer

You configure the DNF Automatic tool by editing the /etc/dnf/automatic.conf configuration file and then restarting the timer unit.

Note that additional alternate timer units are available and can override the default configuration that is specified in the configuration file. Frequently, these timer units are used as handy shortcuts to perform a specific behavior:

  • dnf-automatic-notifyonly.timer: Notifies for available updates

  • dnf-automatic-download.timer: Downloads package updates, but does not install them

  • dnf-automatic-install.timer: Downloads and automatically installs package updates

You enable the required behavior by running:

# systemctl enable --now dnf-automatic-install.timer