jenkins插件地址装不了插件

jenkins插件地址装不了插件

在进行jenkins插件安装时,发现报错,安装失败,提示无法解析域名
jenkins插件地址装不了插件_第1张图片

java.net.UnknownHostException: updates.jenkins-ci.org
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
	at java.net.Socket.connect(Socket.java:589)
	at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
	at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
	at sun.net.www.http.HttpClient.New(HttpClient.java:339)
	at sun.net.www.http.HttpClient.New(HttpClient.java:357)
	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1220)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050)
	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:984)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1564)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
	at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:3000)
	at java.net.URLConnection.getHeaderFieldLong(URLConnection.java:629)
	at java.net.URLConnection.getContentLengthLong(URLConnection.java:501)
	at java.net.URLConnection.getContentLength(URLConnection.java:485)
	at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1264)
Caused: java.net.UnknownHostException: updates.jenkins-ci.org
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
	at sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1944)
	at sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1939)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1938)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1508)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
	at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1280)
Caused: java.io.IOException: Failed to load http://updates.jenkins-ci.org/download/war/2.251/jenkins.war to /usr/local/jenkins/jenkins.war.tmp
	at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1287)
Caused: java.io.IOException: Failed to download from http://updates.jenkins-ci.org/download/war/2.251/jenkins.war
	at hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1321)
	at hudson.model.UpdateCenter$DownloadJob._run(UpdateCenter.java:1869)
	at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1843)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:118)
	at java.lang.Thread.run(Thread.java:748)

去检查更新中心: 发现UnknownHostException: mirror.esuni.jp 时发生错误
**在这里插入图片描述
**
我尝试把https改成http或者换成清华源都不行,都是这样的,然后我插件更新和下载都不行了,都下载不下来
又有的说将文件中的google换成baidu,试了之后还是不行
[root@localhost updates]# vim default.json
{“connectionCheckUrl”:“http://www.google.com/”

突然想到是域名解析失败,不一定是jenkins的问题,也可能是内网的问题,检查虚拟机,发现果然是网络出现了问题
[root@localhost ~]# ping www.baidu.com
ping: www.baidu.com: 未知的名称或服务
查看后发现是以前设置的dns出了问题,修改后重启网络服务,再次更新就正常了

出现问题还是要仔细观察,要是第一时间发现是网络的问题,也不会查那么久了,记录一下,防止遗忘

你可能感兴趣的:(jenkins相关)