RHEL 7のリリースバージョンのアップグレードを抑止

Facebooktwittermail

Red Hat Enterprise Linux 7でサーバ構築するとウィルス対策やバックアップソフトなど商用アプリケーションをインストールする場合があります。

その場合、商用アプリケーションの対応バージョン、カーネルを考慮する必要があり、むやみにyum updateは避ける必要があります。

yum updateで除外する方法です。
How do I exclude kernel or other packages from getting updated in Red Hat Enterprise Linux while updating system via yum?
https://access.redhat.com/solutions/10185
※RHNアカウントでログインしないと全文が読めません。

  • Kernelのアップデート除外
  • リリースバージョンのアップデート除外
  • 複数除外指定
  • /etc/yum.confで指定
  • 複数指定はカンマかスペースで区切り、複数行は書けません。

RHEL 7.3で実行したところexclude=redhat-release* を指定しないと下記の更新が行われ7.3が7.5にアップグレードされてしまいます。

またConflictエラーも発生しました。

yum update fails with “initscripts conflicts with redhat-release-server-7.2-9.el7.x86_64” error.
https://access.redhat.com/solutions/3423391

上記は7.2の事例ですが、7.3でも同様のエラーが発生したので下記を追加しyum updateが成功、7.3のままになりました。

Leave a Reply