ホスト(RHEL8)とコンテナ(UBI8)のサブスクリプションが一致しません。

ホスト(RHEL8)とコンテナ(UBI8)のサブスクリプションが一致しません。

~によるとRHELドキュメントデフォルトでは、インターネット上のすべてのチュートリアルで、私のPodmanコンテナはホスト購読を利用する必要があります。

しかし、私の知る限りではありません...

私のホストには次のものがあります。

# yum repolist enabled
Updating Subscription Management repositories.
repo id                                         repo name
dirsrv-11-for-rhel-8-x86_64-rpms                Red Hat Directory Server 11 for RHEL 8 x86_64 (RPMs)   <= I enabled this repo on the host, thanks to my subscription
rhel-8-for-x86_64-appstream-rpms                Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)
rhel-8-for-x86_64-baseos-rpms                   Red Hat Enterprise Linux 8 for x86_64 - BaseOS (RPMs)

ただし、Podmanコンテナ内では、次のことを行います。

# yum repolist enabled
Updating Subscription Management repositories.
Unable to read consumer identity    <= this does not look good....
Subscription Manager is operating in container mode.
repo id                                    repo name
ubi-8-appstream                            Red Hat Universal Base Image 8 (RPMs) - AppStream
ubi-8-baseos                               Red Hat Universal Base Image 8 (RPMs) - BaseOS
ubi-8-codeready-builder                    Red Hat Universal Base Image 8 (RPMs) - CodeReady Builder
 <= My repo is missing !

コンテナ内で必要なファイルにアクセスできます。

# ls -la /run/secrets/
total 260
drwxr-xr-x. 4 root root    120 Aug 29 16:19 .
drwxr-xr-x. 1 root root   4096 Aug 29 16:22 ..
drwxr-xr-x. 2 root root     72 Aug 23 13:08 etc-pki-entitlement
-rw-r--r--. 1 root root 257134 Aug 26 12:40 redhat.repo
drwxr-xr-x. 6 root root    104 Aug 23 09:00 rhsm
-rw-r--r--. 1 root root      0 Aug 29 16:19 system-fips

何が起こっているのか知っていますか?

ご協力ありがとうございます!

国家規格

編集:私のシステムに関するいくつかの情報:

# cat /etc/os-release
NAME="Red Hat Enterprise Linux"
VERSION="8.6 (Ootpa)"
ID="rhel"
ID_LIKE="fedora"
VERSION_ID="8.6"
PLATFORM_ID="platform:el8"
PRETTY_NAME="Red Hat Enterprise Linux 8.6 (Ootpa)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:redhat:enterprise_linux:8::baseos"
HOME_URL="https://www.redhat.com/"
DOCUMENTATION_URL="https://access.redhat.com/documentation/red_hat_enterprise_linux/8/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"

REDHAT_BUGZILLA_PRODUCT="Red Hat Enterprise Linux 8"
REDHAT_BUGZILLA_PRODUCT_VERSION=8.6
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux"
REDHAT_SUPPORT_PRODUCT_VERSION="8.6"

# podman -v
podman version 4.1.1

# buildah -v
buildah version 1.26.2 (image-spec 1.0.2-dev, runtime-spec 1.0.2-dev)

#  yum --version
4.4.2
  Installed: rpm-0:4.14.3-23.el8.x86_64 at Thu Aug 25 09:26:36 2022
  Built    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla> at Tue Apr  5 18:38:09 2022

ベストアンサー1

それでも助けが必要かどうかはわかりませんが、同様の問題が発生しました。私の場合は、VirtualBoxでRHEL 8.7 VMを使用しています。私はほぼ同じ問題を抱えています。私にとっては、WindowsホストにDockerがインストールされていたからです。仮想化機能のいくつかはVirtualBoxと混同されているようです。この問題を解決するために、アプリと機能>プログラムと機能> Windows機能のオンまたはオフに移動しました。表示されるハイパーバイザーまたは仮想マシン機能(特に仮想マシンプラットフォーム)を無効にします。その後、システムを再起動し、仮想マシンを再起動しましたが、すべてがうまくいきました。それでもエラーメッセージが表示されますが、スクリプトは実行され、必要なすべてのリポジトリにアクセスします。これにより、ホストシステムのDockerがクラッシュします。問題を解決するには、削除して再インストールする必要があります。これが役に立つことを願っています。

おすすめ記事