无法在 rhel8 中使用 yum 更新 jenkins

发布于 2025-01-21 03:44:58 字数 1712 浏览 3 评论 0原文

我已经按照他们的文档安装了詹金斯。然后,当我尝试更新Jenkins时,会给这些Wierd错误。港口443和80开放。是否可以解决这个问题。

日志:

[root@server ~]# cat /etc/yum.repos.d/jenkins.repo
[jenkins]
name=Jenkins-stable
baseurl=http://pkg.jenkins.io/redhat-stable
gpgcheck=1 
[root@server ~]# cat /etc/yum.conf                                                                                           
[main]
gpgcheck=1
installonly_limit=3
clean_requirements_on_remove=True
best=True
skip_if_unavailable=False
ip_resolve=4
[root@mcdefrapl008 ~]#
[root@server ~]# yum update                                                                                                
Jenkins-stable                                                                                     0.0  B/s |   0  B     00:00    
Errors during downloading metadata for repository 'jenkins':
  - Curl error (56): Failure when receiving data from the peer for http://pkg.jenkins.io/redhat-stable/repodata/repomd.xml [Recv fa
ilure: Connection reset by peer]
Error: Failed to download metadata for repo 'jenkins': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors
 were tried
[root@server ~]# curl http://pkg.jenkins.io/redhat-stable/repodata/repomd.xml -v
*   Trying 151.101.2.133...
* TCP_NODELAY set
* Connected to pkg.jenkins.io (151.101.2.133) port 80 (#0)
> GET /redhat-stable/repodata/repomd.xml HTTP/1.1
> Host: pkg.jenkins.io
> User-Agent: curl/7.61.1
> Accept: */*
> 
* Recv failure: Connection reset by peer
* Closing connection 0
curl: (56) Recv failure: Connection reset by peer
[root@mcdefrapl008 ~]#

只是提到,当我在浏览器中打开URL时,它将重定向到HTTPS。

I have installed the jenkins as per their documentation. And then when i try to update jenkins its giving these wierd errors. The ports 443 and 80 are open. Can any assist on this issues.

Logs:

[root@server ~]# cat /etc/yum.repos.d/jenkins.repo
[jenkins]
name=Jenkins-stable
baseurl=http://pkg.jenkins.io/redhat-stable
gpgcheck=1 
[root@server ~]# cat /etc/yum.conf                                                                                           
[main]
gpgcheck=1
installonly_limit=3
clean_requirements_on_remove=True
best=True
skip_if_unavailable=False
ip_resolve=4
[root@mcdefrapl008 ~]#
[root@server ~]# yum update                                                                                                
Jenkins-stable                                                                                     0.0  B/s |   0  B     00:00    
Errors during downloading metadata for repository 'jenkins':
  - Curl error (56): Failure when receiving data from the peer for http://pkg.jenkins.io/redhat-stable/repodata/repomd.xml [Recv fa
ilure: Connection reset by peer]
Error: Failed to download metadata for repo 'jenkins': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors
 were tried
[root@server ~]# curl http://pkg.jenkins.io/redhat-stable/repodata/repomd.xml -v
*   Trying 151.101.2.133...
* TCP_NODELAY set
* Connected to pkg.jenkins.io (151.101.2.133) port 80 (#0)
> GET /redhat-stable/repodata/repomd.xml HTTP/1.1
> Host: pkg.jenkins.io
> User-Agent: curl/7.61.1
> Accept: */*
> 
* Recv failure: Connection reset by peer
* Closing connection 0
curl: (56) Recv failure: Connection reset by peer
[root@mcdefrapl008 ~]#

Just to mention, when i open the url in the browser it is redirecting to https.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

瞳孔里扚悲伤 2025-01-28 03:44:58

YUM不要自动重定向https。因此,请在您的repo https中设置,然后重试。

[jenkins]
name=Jenkins-stable
baseurl=https://pkg.jenkins.io/redhat-stable
gpgcheck=1 

yum do not redirect to https automatically. So set in your repo https and try again.

[jenkins]
name=Jenkins-stable
baseurl=https://pkg.jenkins.io/redhat-stable
gpgcheck=1 
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文