「yum list update」を実行するたびに、このエラーが再発生します。

「yum list update」を実行するたびに、このエラーが再発生します。
# yum list updates
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management.
You can use subscription-manager to register.

設定されたリポジトリの1つが失敗し(不明)、yumにキャッシュされたデータが不足しているため、続行できません。この時点でyumができる唯一の安全なことは失敗です。この問題を「修正」する方法はいくつかあります。

 1. Contact the upstream for the repository and get them to fix the problem.

 2. Reconfigure the baseurl/etc. for the repository, to point to a working
    upstream. This is most often useful if you are using a newer
    distribution release than is supported by the repository (and the
    packages for the previous distribution release still work).

 3. Run the command with the repository temporarily disabled
        yum --disablerepo=<repoid> ...

 4. Disable the repository permanently, so yum won't use it by default. Yum
    will then just ignore the repository until you permanently enable it
    again or use --enablerepo for temporary usage:

        yum-config-manager --disable <repoid>
    or
        subscription-manager repos --disable=<repoid>

 5. Configure the failing repository to be skipped, if it is unavailable.
    Note that yum will try to contact the repo. when it runs most commands,
    so will have to try and fail each time (and thus. yum will be much
    slower). If it is a very temporary problem though, this is often a nice
    compromise:

        yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true

ベストアンサー1

このコマンドを実行するたびに、このエラーが再発生します。誰もが解決策を知っていますか?

はい、そのコマンドの実行を中止してください:)


すべてのリポジトリ定義は/etc/yum.repos.d/

あなたは一つ持っています。 redhat.repoファイルをインストールしましたが、rhelをインストールしましたが(大丈夫です)、インストールしたことがないからです。活動的な与えられたrhelライセンスでインストールしています...これは必ずしも悪いわけではありません。これは、システムを適切に更新し、Redhatが提供できる他のソフトウェアやライブラリをインストールするための公式のRedhatリポジトリにアクセスできないことを意味します。 。

たとえば、私のredhat.repoファイルは次のようになります。

#
# Certificate-Based Repositories
# Managed by (rhsm) subscription-manager
#
# *** This file is auto-generated.  Changes made here will be over-written. ***
# *** Use "subscription-manager repo-override --help" if you wish to make changes. ***
#
# If this file is empty and this system is subscribed consider
# a "yum repolist" to refresh available repos
#

[rhel-7-server-extras-rpms]
metadata_expire = 86400
enabled_metadata = 1
sslclientcert = /etc/pki/entitlement/16959377048969.pem
baseurl = https://cdn.redhat.com/content/dist/rhel/server/7/7Server/$basearch/extras/os
proxy =
ui_repoid_vars = basearch
sslverify = 1
name = Red Hat Enterprise Linux 7 Server - Extras (RPMs)
sslclientkey = /etc/pki/entitlement/169048969744555-key.pem
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
enabled = 1
sslcacert = /etc/rhsm/ca/redhat-uep.pem
gpgcheck = 1

[rhel-7-server-rpms]
metadata_expire = 86400
enabled_metadata = 1
sslclientcert = /etc/pki/entitlement/1695934543375315.pem
baseurl = https://cdn.redhat.com/content/dist/rhel/server/7/$releasever/$basearch/os
proxy =
ui_repoid_vars = releasever basearch
sslverify = 1
name = Red Hat Enterprise Linux 7 Server (RPMs)
sslclientkey = /etc/pki/entitlement/1695935504896975315-key.pem
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
enabled = 1
sslcacert = /etc/rhsm/ca/redhat-uep.pem
gpgcheck = 1

より多くの内容がありますが、enabled=0記入される項目は購入したrhelライセンスによって異なります。しかし、上記の2つは基本的に基本機能に必要な主な機能です。

epel-release-latest-7.noarch.rpm次の中から選択することもできます。https://fedoraproject.org/wiki/EPEL

または、今インターネットに接続している場合は、今することができます。

yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm

またはrhel8の場合:yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

これにより/etc/yum.repos.d/epel.repo、.EPELが無料であることがわかるので、今これを行い、EPELが提供するすべてにアクセスできます。ただし、EPELはカーネルのアップデートを提供していないため、Redhatリポジトリにシステムを登録するにはデフォルトのrhelサブスクリプションを支払う必要があります。

また、ほとんどは無料で、一部は有料である他の多くの店を指すことができることも知っておいてください。 CentOSはRHELで、CentOSは無料で、公式の[有料]サポートはありません。

https://wiki.centos.org/AdditionalResources/Repositories

個人/家庭/エンターテイメント目的でLinuxを使用する場合は、必ずCentOSを使用してください。 RHELを使用しなくても何も失うことはありません。動作するシステムで合法性がある場合、会社はrhelの購読料を支払う必要があります。しかし、多くの人が作業環境で正式にCentOSを使用していることに注意してください。 CentOSはrhelのように有料の公式サポートを提供していないことに注意してください。

おすすめ記事