Connection issue with Jenkins slave on Windows Azure

后端 未结 2 1332
盖世英雄少女心
盖世英雄少女心 2021-01-18 05:41

I\'ve set up a Jenkins slave node on a Windows Azure VM. When building on that node the project runs smoothly for about 20-30 minutes after which the connection gets dropped

2条回答
  •  [愿得一人]
    2021-01-18 06:15

    I am also setting up Jenkins CI in Azure and was getting this same problem. Specifically, I would see this error in the Jenkins slave error log:

    SEVERE: I/O error in channel channel
    java.net.SocketException: Connection reset
    

    To work around it, you need to increase the frequency with which the slave pings the master. You can do this by adding the Dhudson.slaves.ChannelPinger.pingInterval system property to your master jenkins.xml file.

    I modified it to ping every 2 minutes and the channel was able to mantain the connection without dropping it. XML looks like this:

    
      -Xrs -Xmx256m -Dhudson.slaves.ChannelPinger.pingInterval=2 
      -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle 
      -jar "%BASE%\jenkins.war" 
      --httpPort=8080
    
    

    For more information you can see the related ticket.

提交回复
热议问题