rhel7 yum repolist 错误

rhel7 yum repolist 错误

yum install xxx因为我在 RHEL7 上按 Ctrl-C

^Chttps://cdn.redhat.com/content/dist/rhel/server/7/7Server/x86_64/os/repodata/repomd.xml: [Errno 14] curl#56 - "Callback aborted"
Trying other mirror.

我收到以下错误。如何修复它?

$ yum repolist
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
Repo rhel-7-server-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/6004208575190148944-key.pem
https://cdn.redhat.com/content/dist/rhel/server/7/7Server/x86_64/os/repodata/repomd.xml: [Errno 14] curl#58 - "unable to load client key: -8178 (SEC_ERROR_BAD_KEY)"
Trying other mirror.

yum clean all没有帮助

答案1

仅基于您的 shell 提示符为$和 not #,我假设您正在以非 root 用户身份运行该命令,因此无法读取 处的授权密钥/etc/pki/entitlement/6004208575190148944-key.pem,该密钥在我的默认 RHEL7 系统上具有以下权限:

-rw-------. 1 root root ...

快速解决方案是在命令前添加 前缀sudo,或者在运行命令之前以 root 身份登录。根据您之前尝试执行的操作,我认为您拥有权限yum install

相关内容