错误:无法下载存储库“appstream”的元数据:repomd.xml 解析器错误

问题描述 投票:0回答:1

我正在尝试在 centOs 8 应用程序流上使用 yum 下载一些软件包。执行命令后,这个错误发生在我身上。

当我使用 yum update 时,我得到:

CentOS Stream 8 - AppStream                                  27 kB/s | 8.5 kB     00:00    
Error: Failed to download metadata for repo 'appstream': repomd.xml parser error: Parse error at line: 36 (Opening and ending tag mismatch: link line 0 and head
)

应用程序流存储库文件是

# CentOS-Stream-AppStream.repo
#
# The #####mirrorlist system uses the connecting IP address of the client and the
# update status of each mirror to pick current mirrors that are geographically
# close to the client.  You should use this for CentOS updates unless you are
# manually picking other mirrors.
#
# If the #####mirrorlist does not work for you, you can try the commented out
# baseurl line instead.

[appstream]
name=CentOS Stream $releasever - AppStream
#####mirrorlist=http://#####mirrorlist.centos.org/?release=$stream&arch=$base#arch&repo=AppStream&infra=$infra
baseurl=http://vault.centos.org/$contentdir/$stream/AppStream/$basearch/os/
gpgcheck=0
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

登录 /var/log/dnf.log :

  File "/usr/lib/python3.6/site-packages/dnf/repo.py", line 573, in load
    ret = self._repo.load()
  File "/usr/lib64/python3.6/site-packages/libdnf/repo.py", line 397, in load
    return _repo.Repo_load(self)
libdnf._error.Error: Failed to download metadata for repo 'appstream': repomd.xml parser error: Parse error at line: 36 (Opening and ending tag mismatch: link line 0 and head
)

/var/log/dnf.librepo.log:

2024-08-30T02:34:14+0300 INFO Librepo version: 1.14.2 with CURL_GLOBAL_ACK_EINTR support (libcurl/7.61.1 OpenSSL/1.1.1k zlib/1.2.11 brotli/1.0.6 libidn2/2.2.0 libpsl/0.20.2 (+libidn2/2.2.0) libssh/0.9.6/openssl/zlib nghttp2/1.33.0)
2024-08-30T02:34:14+0300 INFO Librepo version: 1.14.2 with CURL_GLOBAL_ACK_EINTR support (libcurl/7.61.1 OpenSSL/1.1.1k zlib/1.2.11 brotli/1.0.6 libidn2/2.2.0 libpsl/0.20.2 (+libidn2/2.2.0) libssh/0.9.6/openssl/zlib nghttp2/1.33.0)
2024-08-30T02:34:14+0300 INFO Downloading: http://vault.centos.org/centos/8-stream/AppStream/x86_64/os/repodata/repomd.xml
2024-08-30T02:34:15+0300 WARNING WARNING: Repomd xml parser: Unknown element "html"
centos devops yum system-administration centos8
1个回答
0
投票

如果您访问this页面,您将看到如下文本:

不是 用于安装 CentOS Linux 的更新树:它是 已从主树中删除的旧树的快照 CentOS 服务器作为新的点版本发布。这是提供的 供参考并提供对旧存档版本的访问,我们 不要将安全更新放入此服务器上的树中。请参阅 此链接适用于 CentOS Linux 的活动版本

这解释了为什么您无法更新。 CentOS 8 从 2021 年 12 月 31 日起不再支持

© www.soinside.com 2019 - 2024. All rights reserved.