在这里寻求帮助!
我正在运行Jenkins(v2.134)作为由Rancher(v1.6.16)管理的Docker容器;我使用haproxy(HA-Proxy版本1.6.3 2015/12/25)作为我的负载均衡器。Jenkins JNLP端口配置为50000。haproxy获取TCP端口转发规则(8081 > 50000)
我的从机(macmini)在不同的网络和防火墙后面(这个网络可以到达我的Jenkins Infra)。我使用的是“Tunnel connection through”属性和指定端口“:8081”。端口8081已在防火墙中打开。
我的Jenkins Java版本是-
openjdk version "1.8.0_151"
OpenJDK Runtime Environment (build 1.8.0_151-8u151-b12-1~deb9u1-b12)
我的奴隶Java版本是-
Sun JDK "1.8.0_151"
这是探员日志
*INFO: Setting up agent: my-slave-01*
Sep 26, 2018 2:48:50 PM hudson.remoting.jnlp.Main$CuiListener <init>
INFO: Jenkins agent is running in headless mode.
Sep 26, 2018 2:48:50 PM hudson.remoting.Engine startEngine
INFO: Using Remoting version: 3.23
Sep 26, 2018 2:48:50 PM hudson.remoting.Engine startEngine
WARNING: No Working Directory. Using the legacy JAR Cache location: /Users/jenkins/.jenkins/cache/jars
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Locating server among [http://<My Jenkins URL>/]
Sep 26, 2018 2:48:51 PM org.jenkinsci.remoting.engine.JnlpAgentEndpointResolver resolve
INFO: Remoting server accepts the following protocols: [JNLP4-connect, Ping]
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
*INFO: Agent discovery successful*
*Agent address: <My Jenkins DNS Name>*
*Agent port: 8081*
Identity: b5:c7:33:8d:9c:97:41:3f:e1:b1:b5:31:25:ea:b5:2e
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Handshaking
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Connecting to <My Jenkins DNS>:8081
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Trying protocol: JNLP4-connect
Sep 26, 2018 2:48:51 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Remote identity confirmed: b5:c7:33:8d:9c:97:41:3f:e1:b1:b5:31:25:ea:b5:2e
Sep 26, 2018 2:48:52 PM hudson.remoting.jnlp.Main$CuiListener status
*INFO: Connected*
Sep 26, 2018 2:48:54 PM org.jenkinsci.remoting.util.AnonymousClassWarnings warn
WARNING: Attempt to (de-)serialize anonymous class org.jenkinsci.plugins.envinject.EnvInjectComputerListener$2; see: https://jenkins.io/redirect/serialization-of-anonymous-classes/
Sep 26, 2018 2:49:49 PM hudson.remoting.jnlp.Main$CuiListener status
*INFO: Terminated*
任何帮助将不胜感激。
有没有一种方法可以获得更多的详细日志?
2条答案
按热度按时间z9smfwbn1#
我发现了问题;它是与我的负载均衡器(haproxy)默认超时的TCP连接(如果没有流量),这是50000毫秒。https://cbonte.github.io/haproxy-dconv/configuration-1.5.html
然而,Jenkins ping从站(即哈德逊.slaves.ChannelPinger.pingInterval)的间隔为5分钟(dafault)。https://wiki.jenkins.io/display/JENKINS/Features+controlled+by+system+properties
增加负载均衡器超时,即5分钟解决了这个问题。
oxiaedzo2#
如果以前使用此选项限制过频繁的重新连接,则还可以从参数中删除-noReconnect。
您可以阅读有关此选项here的信息。