Pan*_*ini 4 jnlp haproxy jenkins docker rancher
在这里寻求帮助!
我正在运行 Jenkins(v2.134) 作为由 Rancher(v1.6.16) 管理的 docker 容器;我使用 haproxy(HA-Proxy version 1.6.3 2015/12/25)作为我的负载均衡器。Jenkins JNLP 端口配置为 50000。haproxy 得到了 TCP 端口转发的规则(8081 > 50000)
我的奴隶 (macmini) 在不同的网络和防火墙后面(这个网络可以到达我的 Jenkins Infra)。我正在使用“隧道连接通过”属性和指定的端口“:8081”。8081 端口已经在防火墙中打开了。
我的 Jenkins Java 版本是 -
openjdk version "1.8.0_151"
OpenJDK Runtime Environment (build 1.8.0_151-8u151-b12-1~deb9u1-b12)
Run Code Online (Sandbox Code Playgroud)
我的 Slave Java 版本是 -
Sun JDK "1.8.0_151"
Run Code Online (Sandbox Code Playgroud)
这是代理日志-
*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*
Run Code Online (Sandbox Code Playgroud)
任何帮助将不胜感激。
有没有办法获得更详细的日志?
我发现了问题;这是我的负载平衡器(haproxy)TCP 连接(如果没有流量)的默认超时为 50000 毫秒。 https://cbonte.github.io/haproxy-dconv/configuration-1.5.html
然而,詹金斯到奴隶 iehudson.slaves.ChannelPinger.pingInterval 的 ping 间隔是 5 分钟(dafault)。 https://wiki.jenkins.io/display/JENKINS/Features+controlled+by+system+properties
增加负载平衡器超时,即 > 5 分钟解决了这个问题。
|   归档时间:  |  
           
  |  
        
|   查看次数:  |  
           2830 次  |  
        
|   最近记录:  |