Skip to main content
简体中文版经机器翻译而成,仅供参考。如与英语版出现任何冲突,应以英语版为准。

启用对存储库的访问

贡献者

您应启用对存储库的访问、以便ONTAP 调解器可以在安装过程中访问所需的软件包

步骤
  1. 确定必须访问哪些存储库、如下表所示:

    操作系统

    您必须提供对这些存储库的访问权限 …​

    RHEL 7.x

    • rhel-7-server-optional -rpms

    RHEL 8.x

    • rhel-8-for-x86_64 — basos-rpms

    • rhel-8-for-x86_64 — AppStream — rpms

    RHEL 9.x

    • rell-9-for x86、64-baseos-rpms

    • rell-9-for x86、64-AppStream-rpms

    CentOS 7.x

    • C7.6.1810 —基本存储库

    落基Linux 8.

    • AppStream

    • baseos

    落基Linux 9

    • AppStream

    • baseos

  2. 使用以下过程之一启用对上面列出的存储库的访问、以便ONTAP 调解器可以在安装过程中访问所需的软件包。

适用于 RHEL 7.x 操作系统的操作步骤

如果您的操作系统为*RHEL 7.x*,请使用此操作步骤 来访问存储库:

步骤
  1. 订阅所需的存储库:

    subscription-manager repos --enable rhel-7-server-optional-rpms

    以下示例显示了此命令的执行情况:

    [root@localhost ~]# subscription-manager repos --enable rhel-7-server-optional-rpms
    Repository 'rhel-7-server-optional-rpms' is enabled for this system.
  2. 运行 yum repolist 命令:

    以下示例显示了此命令的执行情况。列表中应显示 rhel-7-server-optional -rpms 存储库。

    [root@localhost ~]# yum repolist
    Loaded plugins: product-id, search-disabled-repos, subscription-manager
    rhel-7-server-optional-rpms | 3.2 kB  00:00:00
    rhel-7-server-rpms | 3.5 kB  00:00:00
    (1/3): rhel-7-server-optional-rpms/7Server/x86_64/group              |  26 kB  00:00:00
    (2/3): rhel-7-server-optional-rpms/7Server/x86_64/updateinfo         | 2.5 MB  00:00:00
    (3/3): rhel-7-server-optional-rpms/7Server/x86_64/primary_db         | 8.3 MB  00:00:01
    repo id                                      repo name                                             status
    rhel-7-server-optional-rpms/7Server/x86_64   Red Hat Enterprise Linux 7 Server - Optional (RPMs)   19,447
    rhel-7-server-rpms/7Server/x86_64            Red Hat Enterprise Linux 7 Server (RPMs)              26,758
    repolist: 46,205
    [root@localhost ~]#
适用于RHEL 8.x操作系统的操作步骤

如果您的操作系统为*RHEL 8.x*,请使用此操作步骤来访问存储库:

步骤
  1. 订阅所需的存储库:

    subscription-manager repos --enable rhel-8-for-x86_64-baseos-rpms

    subscription-manager repos --enable rhel-8-for-x86_64-appstream-rpms

    以下示例显示了此命令的执行情况:

    [root@localhost ~]# subscription-manager repos --enable rhel-8-for-x86_64-baseos-rpms
    Repository 'rhel-8-for-x86_64-baseos-rpms' is enabled for this system.
    [root@localhost ~]# subscription-manager repos --enable rhel-8-for-x86_64-appstream-rpms
    Repository 'rhel-8-for-x86_64-appstream-rpms' is enabled for this system.
  2. 运行 yum repolist 命令:

    新订阅的存储库应显示在列表中。

适用于RHEL 9.x操作系统的操作步骤

如果您的操作系统为*RHEL 9.x*,请使用此操作步骤来访问存储库:

步骤
  1. 订阅所需的存储库:

    subscription-manager repos --enable rhel-9-for-x86_64-baseos-rpms

    subscription-manager repos --enable rhel-9-for-x86_64-appstream-rpms

    以下示例显示了此命令的执行情况:

    [root@localhost ~]# subscription-manager repos --enable rhel-9-for-x86_64-baseos-rpms
    Repository 'rhel-9-for-x86_64-baseos-rpms' is enabled for this system.
    [root@localhost ~]# subscription-manager repos --enable rhel-9-for-x86_64-appstream-rpms
    Repository 'rhel-9-for-x86_64-appstream-rpms' is enabled for this system.
  2. 运行 yum repolist 命令:

    新订阅的存储库应显示在列表中。

适用于 CentOS 7.x 操作系统的操作步骤

如果您的操作系统为*CentOS 7.x*,请使用此操作步骤 来访问存储库:

备注 以下示例显示的是CentOS 7.6的存储库、可能不适用于其他CentOS版本。使用适用于您的CentOS版本的基础存储库。
步骤
  1. 添加 C7.6.1810 —基本存储库。C7.6.1810 -基本存储库包含ONTAP 调解器所需的"kernel-devel"软件包。

  2. 将以下行添加到 /etc/yum.repos.d/Centos-vault.repo.

    [C7.6.1810-base]
    name=CentOS-7.6.1810 - Base
    baseurl=http://vault.centos.org/7.6.1810/os/$basearch/
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
    enabled=1
  3. 运行 yum repolist 命令:

    以下示例显示了此命令的执行情况。CentOS-7.6.1810 —基本存储库应显示在列表中。

    Loaded plugins: fastestmirror
    Loading mirror speeds from cached hostfile
     * base: distro.ibiblio.org
     * extras: distro.ibiblio.org
     * updates: ewr.edge.kernel.org
    C7.6.1810-base                                 | 3.6 kB  00:00:00
    (1/2): C7.6.1810-base/x86_64/group_gz          | 166 kB  00:00:00
    (2/2): C7.6.1810-base/x86_64/primary_db        | 6.0 MB  00:00:04
    repo id                      repo name               status
    C7.6.1810-base/x86_64        CentOS-7.6.1810 - Base  10,019
    base/7/x86_64                CentOS-7 - Base         10,097
    extras/7/x86_64              CentOS-7 - Extras       307
    updates/7/x86_64             CentOS-7 - Updates      1,010
    repolist: 21,433
    [root@localhost ~]#
适用于Rocky Linux 8或9操作系统的操作步骤

如果您的操作系统是*Rocky Linux 8*或*Rocky Linux 9*,请使用此操作步骤 来访问存储库:

步骤
  1. 订阅所需的存储库:

    dnf config-manager --set-enabled baseos

    dnf config-manager --set-enabled appstream

  2. 执行 clean 操作:

    dnf clean all

  3. 验证存储库列表:

    dnf repolist

[root@localhost ~]# dnf config-manager --set-enabled baseos
[root@localhost ~]# dnf config-manager --set-enabled appstream
[root@localhost ~]# dnf clean all
[root@localhost ~]# dnf repolist
repo id                        repo name
appstream                      Rocky Linux 8 - AppStream
baseos                         Rocky Linux 8 - BaseOS
[root@localhost ~]#
[root@localhost ~]# dnf config-manager --set-enabled baseos
[root@localhost ~]# dnf config-manager --set-enabled appstream
[root@localhost ~]# dnf clean all
[root@localhost ~]# dnf repolist
repo id                        repo name
appstream                      Rocky Linux 9 - AppStream
baseos                         Rocky Linux 9 - BaseOS
[root@localhost ~]#