Hi, I am using Jenkins 2.387.2 LTS version. I encountered my builds are disappearing for some jobs, when I login to the Jenkins server(Ubuntu), I see build.xml does not exist for the disappeared build, but I still see the log. When I look into the logs I see the build is failed with connection issue to the Jenkins master. But in the previous versions of Jenkins I don’t see this missing builds.
Hello @nithinkrishn and welcome to this community
Would you have any logs to share?
Hello @poddingue, please find the logs and missing build.xml screenshot
FATAL: command execution failed
java.nio.channels.ClosedChannelException
at org.jenkinsci.remoting.protocol.impl.ChannelApplicationLayer.onReadClosed(ChannelApplicationLayer.java:241)
at org.jenkinsci.remoting.protocol.ApplicationLayer.onRecvClosed(ApplicationLayer.java:221)
at org.jenkinsci.remoting.protocol.ProtocolStack$Ptr.onRecvClosed(ProtocolStack.java:825)
at org.jenkinsci.remoting.protocol.FilterLayer.onRecvClosed(FilterLayer.java:289)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.onRecvClosed(SSLEngineFilterLayer.java:177)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.switchToNoSecure(SSLEngineFilterLayer.java:279)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.processWrite(SSLEngineFilterLayer.java:501)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.processQueuedWrites(SSLEngineFilterLayer.java:244)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.doSend(SSLEngineFilterLayer.java:196)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.doCloseSend(SSLEngineFilterLayer.java:209)
at org.jenkinsci.remoting.protocol.ProtocolStack$Ptr.doCloseSend(ProtocolStack.java:793)
at org.jenkinsci.remoting.protocol.ApplicationLayer.doCloseWrite(ApplicationLayer.java:172)
at org.jenkinsci.remoting.protocol.impl.ChannelApplicationLayer$ByteBufferCommandTransport.closeWrite(ChannelApplicationLayer.java:343)
at hudson.remoting.Channel.close(Channel.java:1494)
at hudson.remoting.Channel.close(Channel.java:1447)
at hudson.slaves.SlaveComputer.closeChannel(SlaveComputer.java:940)
at hudson.slaves.SlaveComputer.kill(SlaveComputer.java:906)
at hudson.model.AbstractCIBase.killComputer(AbstractCIBase.java:97)
at jenkins.model.Jenkins.lambda$_cleanUpDisconnectComputers$11(Jenkins.java:3727)
at hudson.model.Queue._withLock(Queue.java:1395)
at hudson.model.Queue.withLock(Queue.java:1269)
at jenkins.model.Jenkins._cleanUpDisconnectComputers(Jenkins.java:3723)
at jenkins.model.Jenkins.cleanUp(Jenkins.java:3604)
at hudson.WebAppMain.contextDestroyed(WebAppMain.java:374)
at org.eclipse.jetty.server.handler.ContextHandler.callContextDestroyed(ContextHandler.java:1058)
at org.eclipse.jetty.servlet.ServletContextHandler.callContextDestroyed(ServletContextHandler.java:636)
at org.eclipse.jetty.server.handler.ContextHandler.contextDestroyed(ContextHandler.java:1015)
at org.eclipse.jetty.servlet.ServletHandler.doStop(ServletHandler.java:306)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.security.SecurityHandler.doStop(SecurityHandler.java:411)
at org.eclipse.jetty.security.ConstraintSecurityHandler.doStop(ConstraintSecurityHandler.java:413)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.session.SessionHandler.doStop(SessionHandler.java:497)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.handler.ContextHandler.stopContext(ContextHandler.java:1038)
at org.eclipse.jetty.servlet.ServletContextHandler.stopContext(ServletContextHandler.java:399)
at org.eclipse.jetty.webapp.WebAppContext.stopContext(WebAppContext.java:1311)
at org.eclipse.jetty.server.handler.ContextHandler.doStop(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletContextHandler.doStop(ServletContextHandler.java:312)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.Server.doStop(Server.java:517)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at winstone.Launcher.shutdown(Launcher.java:340)
at winstone.ShutdownHook.run(ShutdownHook.java:28)
Caused: java.io.IOException: Backing channel 'JNLP4-connect connection from ************** is disconnected.
at hudson.remoting.RemoteInvocationHandler.channelOrFail(RemoteInvocationHandler.java:215)
at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:285)
at com.sun.proxy.$Proxy184.isAlive(Unknown Source)
at hudson.Launcher$RemoteLauncher$ProcImpl.isAlive(Launcher.java:1215)
at hudson.Launcher$RemoteLauncher$ProcImpl.join(Launcher.java:1207)
at hudson.tasks.CommandInterpreter.join(CommandInterpreter.java:195)
at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:145)
at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:92)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner$2.run(BuildStepRunner.java:112)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner$Fail.conditionalRun(BuildStepRunner.java:156)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner.perform(BuildStepRunner.java:107)
at org.jenkinsci.plugins.conditionalbuildstep.singlestep.SingleConditionalBuilder.perform(SingleConditionalBuilder.java:108)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:818)
at hudson.model.Build$BuildExecution.build(Build.java:199)
at hudson.model.Build$BuildExecution.doRun(Build.java:164)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526)
at hudson.model.Run.execute(Run.java:1900)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
FATAL: Unable to delete script file C:\Users\jenkins\AppData\Local\Temp\jenkins16913234792227668858.bat
java.nio.channels.ClosedChannelException
at org.jenkinsci.remoting.protocol.impl.ChannelApplicationLayer.onReadClosed(ChannelApplicationLayer.java:241)
at org.jenkinsci.remoting.protocol.ApplicationLayer.onRecvClosed(ApplicationLayer.java:221)
at org.jenkinsci.remoting.protocol.ProtocolStack$Ptr.onRecvClosed(ProtocolStack.java:825)
at org.jenkinsci.remoting.protocol.FilterLayer.onRecvClosed(FilterLayer.java:289)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.onRecvClosed(SSLEngineFilterLayer.java:177)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.switchToNoSecure(SSLEngineFilterLayer.java:279)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.processWrite(SSLEngineFilterLayer.java:501)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.processQueuedWrites(SSLEngineFilterLayer.java:244)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.doSend(SSLEngineFilterLayer.java:196)
at org.jenkinsci.remoting.protocol.impl.SSLEngineFilterLayer.doCloseSend(SSLEngineFilterLayer.java:209)
at org.jenkinsci.remoting.protocol.ProtocolStack$Ptr.doCloseSend(ProtocolStack.java:793)
at org.jenkinsci.remoting.protocol.ApplicationLayer.doCloseWrite(ApplicationLayer.java:172)
at org.jenkinsci.remoting.protocol.impl.ChannelApplicationLayer$ByteBufferCommandTransport.closeWrite(ChannelApplicationLayer.java:343)
at hudson.remoting.Channel.close(Channel.java:1494)
at hudson.remoting.Channel.close(Channel.java:1447)
at hudson.slaves.SlaveComputer.closeChannel(SlaveComputer.java:940)
at hudson.slaves.SlaveComputer.kill(SlaveComputer.java:906)
at hudson.model.AbstractCIBase.killComputer(AbstractCIBase.java:97)
at jenkins.model.Jenkins.lambda$_cleanUpDisconnectComputers$11(Jenkins.java:3727)
at hudson.model.Queue._withLock(Queue.java:1395)
at hudson.model.Queue.withLock(Queue.java:1269)
at jenkins.model.Jenkins._cleanUpDisconnectComputers(Jenkins.java:3723)
at jenkins.model.Jenkins.cleanUp(Jenkins.java:3604)
at hudson.WebAppMain.contextDestroyed(WebAppMain.java:374)
at org.eclipse.jetty.server.handler.ContextHandler.callContextDestroyed(ContextHandler.java:1058)
at org.eclipse.jetty.servlet.ServletContextHandler.callContextDestroyed(ServletContextHandler.java:636)
at org.eclipse.jetty.server.handler.ContextHandler.contextDestroyed(ContextHandler.java:1015)
at org.eclipse.jetty.servlet.ServletHandler.doStop(ServletHandler.java:306)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.security.SecurityHandler.doStop(SecurityHandler.java:411)
at org.eclipse.jetty.security.ConstraintSecurityHandler.doStop(ConstraintSecurityHandler.java:413)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.session.SessionHandler.doStop(SessionHandler.java:497)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.handler.ContextHandler.stopContext(ContextHandler.java:1038)
at org.eclipse.jetty.servlet.ServletContextHandler.stopContext(ServletContextHandler.java:399)
at org.eclipse.jetty.webapp.WebAppContext.stopContext(WebAppContext.java:1311)
at org.eclipse.jetty.server.handler.ContextHandler.doStop(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletContextHandler.doStop(ServletContextHandler.java:312)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:182)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:205)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:97)
at org.eclipse.jetty.server.Server.doStop(Server.java:517)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:132)
at winstone.Launcher.shutdown(Launcher.java:340)
at winstone.ShutdownHook.run(ShutdownHook.java:28)
Caused: hudson.remoting.ChannelClosedException: Channel "hudson.remoting.Channel@d7635ae:JNLP4-connect connection from **********Remote call on JNLP4-connect connection from **************failed. The channel is closing down or has closed down
at hudson.remoting.Channel.call(Channel.java:993)
at hudson.FilePath.act(FilePath.java:1192)
at hudson.FilePath.act(FilePath.java:1181)
at hudson.FilePath.delete(FilePath.java:1728)
at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:163)
at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:92)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner$2.run(BuildStepRunner.java:112)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner$Fail.conditionalRun(BuildStepRunner.java:156)
at org.jenkins_ci.plugins.run_condition.BuildStepRunner.perform(BuildStepRunner.java:107)
at org.jenkinsci.plugins.conditionalbuildstep.singlestep.SingleConditionalBuilder.perform(SingleConditionalBuilder.java:108)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:818)
at hudson.model.Build$BuildExecution.build(Build.java:199)
at hudson.model.Build$BuildExecution.doRun(Build.java:164)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526)
at hudson.model.Run.execute(Run.java:1900)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
Build step ‘Conditional step (single)’ marked build as failure
ERROR: Unable to tear down: null
java.lang.NullPointerException
at hudson.plugins.build_timeout.BuildTimeoutWrapper$EnvironmentImpl.tearDown(BuildTimeoutWrapper.java:197)
at hudson.model.AbstractBuild$AbstractBuildExecution.tearDownBuildEnvironments(AbstractBuild.java:566)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:530)
at hudson.model.Run.execute(Run.java:1900)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
ERROR: Step <91>Archive the artifacts<92> failed: no workspace for vsc-package-windows #679
To my understanding, the error message “java.nio.channels.ClosedChannelException” in your logs indicates that the connection between the Jenkins agent and the Jenkins controller was closed unexpectedly. This could occur due to network issues, firewalls, or other connectivity problems.
As far as I know, when a build is running, Jenkins saves the build.xml file, which contains the build log and other information about the build.
If the connection to the controller is lost, and the build is unable to complete, the build.xml file may not be saved.
In this case, you could maybe see a build in Jenkins that has no build.xml
file and no associated data, but still has a log file.
It’s possible that changes in the newer version of Jenkins you’re using may have caused it to occur more frequently.
It’s also possible that changes in your network or infrastructure have contributed to the problem.
I have never experienced that behaviour, so take it with a grain of salt, it’s just wild guessing.
Connection between Node and master was broken many times before but I haven’t seen build.xml was deleted. This happens only I after updated to the Jenkins LTS version 2.387.2.
Not sure why it is deleting build.xml after upgrading to 2.387.2.
I hope that someone with more knowledge on the topic will join in to assist you. As a reminder, the term “master” to refer to a controller has been deprecated since 2016. For more details, please refer to the link: On Jenkins Terminology Updates.