CentOS と RHEL 8 またはそれ以後のバージョン

CentOS および RHEL 8 以降のバージョンでは、dnf-automatic パッケージを使用することを推奨します。

dnf install dnf-automatic

/etc/dnf/automatic.conf に以下を設定します。

download_updates = yes
apply_updates = yes

自動アップデートを有効にして開始します。

systemctl enable --now dnf-automatic.timer

dnf-automatic のステータスを確認します。

systemctl list-timers *dnf-*

CentOS と RHEL 7 またはそれ以前のバージョン

CentOS および RHEL 7 以前のバージョンでは、yum-cron パッケージを使用することを推奨します。

yum install yum-cron

/etc/yum/yum-cron.conf に以下を設定します。

download_updates = yes
apply_updates = yes

自動アップデートを有効にして開始します。

systemctl start yum-cron.service

openSUSE

まず、自動更新パッケージをインストールする必要があります。

zypper install  yast2-online-update-configuration

次に、以下のコマンドで構成ツール (ncurses ベース) を起動します。

yast2 online_update_configuration

以下の設定を有効にします。

    Automatic Online Update
    Interval: Daily
    Skip Interactive Patches
    Agree with Licenses
    Use delta rpms

「OK」をクリックして設定を確認します。

openSUSE の公式ドキュメントはこちらをご覧ください。