Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-49402

slave fails with java.lang.NoClassDefFoundError: hudson.model.Computer

    Details

    • Similar Issues:

      Description

      We encounter a new but critical issue since about 3 days ago when Jenkins master had an unexpected reboot.

      Slaves (ssh) return this error and the only way to make them work again is to disconnect them and to reconnect them. After this they will work for some time but we have information that the problem appears again after some time.

      We observed this behavior on 5-6 slaves and most of them had this version of Java

      openjdk version "1.8.0_111"
      OpenJDK Runtime Environment (build 1.8.0_111-b15)
      OpenJDK 64-Bit Server VM (build 25.111-b15, mixed mode)

      Master is running on newer java

      openjdk version "1.8.0_151"
      OpenJDK Runtime Environment (build 1.8.0_151-b12)
      OpenJDK 64-Bit Server VM (build 25.151-b12, mixed mode)
      

      Error:

      java.lang.NoClassDefFoundError: hudson.model.Computer
      	at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.withRepository(AbstractGitAPIImpl.java:29)
      	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.withRepository(CliGitAPIImpl.java:71)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:498)
      	at hudson.remoting.RemoteInvocationHandler$RPCRequest.perform(RemoteInvocationHandler.java:895)
      	at hudson.remoting.RemoteInvocationHandler$RPCRequest.call(RemoteInvocationHandler.java:870)
      	at hudson.remoting.RemoteInvocationHandler$RPCRequest.call(RemoteInvocationHandler.java:829)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:153)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
      	at hudson.remoting.Request$2.run(Request.java:336)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      	at ......remote call to qe-virt-seal-13(Native Method)
      	at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1545)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
      	at hudson.remoting.Channel.call(Channel.java:830)
      Caused: java.io.IOException: Remote call on qe-virt-seal-13 failed
      	at hudson.remoting.Channel.call(Channel.java:838)
      	at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:257)
      	at com.sun.proxy.$Proxy90.withRepository(Unknown Source)
      	at org.jenkinsci.plugins.gitclient.RemoteGitImpl.withRepository(RemoteGitImpl.java:235)
      	at hudson.plugins.git.GitSCM.printCommitMessageToLog(GitSCM.java:1195)
      	at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1159)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:113)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:85)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:75)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
      	at hudson.security.ACL.impersonate(ACL.java:260)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at java.lang.Thread.run(Thread.java:748)
      Finished: FAILURE
      

        Attachments

          Issue Links

            Activity

            Hide
            queria Queria Sa-Tas added a comment -

            There is exception recorded on slave:

            com.thoughtworks.xstream.InitializationException: Could not instantiate converter : com.thoughtworks.xstream.converters.extended.DurationConverter : null
            	at com.thoughtworks.xstream.XStream.registerConverterDynamically(XStream.java:904)
            	at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:867)
            	at com.thoughtworks.xstream.XStream.<init>(XStream.java:574)
            	at com.thoughtworks.xstream.XStream.<init>(XStream.java:496)
            	at com.thoughtworks.xstream.XStream.<init>(XStream.java:465)
            	at com.thoughtworks.xstream.XStream.<init>(XStream.java:411)
            	at com.thoughtworks.xstream.XStream.<init>(XStream.java:350)
            	at hudson.util.XStream2.<init>(XStream2.java:89)
            	at jenkins.model.Jenkins.<clinit>(Jenkins.java:5132)
            	at hudson.model.Computer.<clinit>(Computer.java:1747)
            	at hudson.util.ProcessTree.getKillers(ProcessTree.java:157)
            	at hudson.util.ProcessTree$OSProcess.killByKiller(ProcessTree.java:218)
            	at hudson.util.ProcessTree$UnixProcess.kill(ProcessTree.java:660)
            	at hudson.util.ProcessTree$UnixProcess.killRecursively(ProcessTree.java:668)
            	at hudson.util.ProcessTree$Unix.killAll(ProcessTree.java:589)
            	at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:996)
            	at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:987)
            	at hudson.remoting.UserRequest.perform(UserRequest.java:153)
            	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
            	at hudson.remoting.Request$2.run(Request.java:336)
            	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
            	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
            	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
            	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
            	at java.lang.Thread.run(Thread.java:745)
            Caused by: java.lang.reflect.InvocationTargetException
            	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 com.thoughtworks.xstream.XStream.registerConverterDynamically(XStream.java:897)
            	... 24 more
            Caused by: hudson.remoting.RemotingSystemException: java.lang.InterruptedException
            	at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:273)
            	at com.sun.proxy.$Proxy5.getResources2(Unknown Source)
            	at hudson.remoting.RemoteClassLoader.findResources(RemoteClassLoader.java:463)
            	at java.lang.ClassLoader.getResources(ClassLoader.java:1142)
            	at java.util.ServiceLoader$LazyIterator.hasNextService(ServiceLoader.java:348)
            	at java.util.ServiceLoader$LazyIterator.hasNext(ServiceLoader.java:393)
            	at java.util.ServiceLoader$1.hasNext(ServiceLoader.java:474)
            	at javax.xml.datatype.FactoryFinder$1.run(FactoryFinder.java:296)
            	at java.security.AccessController.doPrivileged(Native Method)
            	at javax.xml.datatype.FactoryFinder.findServiceProvider(FactoryFinder.java:292)
            	at javax.xml.datatype.FactoryFinder.find(FactoryFinder.java:268)
            	at javax.xml.datatype.DatatypeFactory.newInstance(DatatypeFactory.java:145)
            	at com.thoughtworks.xstream.converters.extended.DurationConverter$1.getFactory(DurationConverter.java:39)
            	at com.thoughtworks.xstream.converters.extended.DurationConverter.<init>(DurationConverter.java:36)
            	... 29 more
            Caused by: java.lang.InterruptedException
            	at java.lang.Object.wait(Native Method)
            	at hudson.remoting.Request.call(Request.java:147)
            	at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:260)
            	... 42 more
            

            possibly related to http://x-stream.github.io/jira/537/
            also possibly related seems to be that we got pipeline-maven 3.2.0 installed

            Show
            queria Queria Sa-Tas added a comment - There is exception recorded on slave: com.thoughtworks.xstream.InitializationException: Could not instantiate converter : com.thoughtworks.xstream.converters.extended.DurationConverter : null at com.thoughtworks.xstream.XStream.registerConverterDynamically(XStream.java:904) at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:867) at com.thoughtworks.xstream.XStream.<init>(XStream.java:574) at com.thoughtworks.xstream.XStream.<init>(XStream.java:496) at com.thoughtworks.xstream.XStream.<init>(XStream.java:465) at com.thoughtworks.xstream.XStream.<init>(XStream.java:411) at com.thoughtworks.xstream.XStream.<init>(XStream.java:350) at hudson.util.XStream2.<init>(XStream2.java:89) at jenkins.model.Jenkins.<clinit>(Jenkins.java:5132) at hudson.model.Computer.<clinit>(Computer.java:1747) at hudson.util.ProcessTree.getKillers(ProcessTree.java:157) at hudson.util.ProcessTree$OSProcess.killByKiller(ProcessTree.java:218) at hudson.util.ProcessTree$UnixProcess.kill(ProcessTree.java:660) at hudson.util.ProcessTree$UnixProcess.killRecursively(ProcessTree.java:668) at hudson.util.ProcessTree$Unix.killAll(ProcessTree.java:589) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:996) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:987) at hudson.remoting.UserRequest.perform(UserRequest.java:153) at hudson.remoting.UserRequest.perform(UserRequest.java:50) at hudson.remoting.Request$2.run(Request.java:336) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang. Thread .run( Thread .java:745) Caused by: java.lang.reflect.InvocationTargetException 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 com.thoughtworks.xstream.XStream.registerConverterDynamically(XStream.java:897) ... 24 more Caused by: hudson.remoting.RemotingSystemException: java.lang.InterruptedException at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:273) at com.sun.proxy.$Proxy5.getResources2(Unknown Source) at hudson.remoting.RemoteClassLoader.findResources(RemoteClassLoader.java:463) at java.lang. ClassLoader .getResources( ClassLoader .java:1142) at java.util.ServiceLoader$LazyIterator.hasNextService(ServiceLoader.java:348) at java.util.ServiceLoader$LazyIterator.hasNext(ServiceLoader.java:393) at java.util.ServiceLoader$1.hasNext(ServiceLoader.java:474) at javax.xml.datatype.FactoryFinder$1.run(FactoryFinder.java:296) at java.security.AccessController.doPrivileged(Native Method) at javax.xml.datatype.FactoryFinder.findServiceProvider(FactoryFinder.java:292) at javax.xml.datatype.FactoryFinder.find(FactoryFinder.java:268) at javax.xml.datatype.DatatypeFactory.newInstance(DatatypeFactory.java:145) at com.thoughtworks.xstream.converters.extended.DurationConverter$1.getFactory(DurationConverter.java:39) at com.thoughtworks.xstream.converters.extended.DurationConverter.<init>(DurationConverter.java:36) ... 29 more Caused by: java.lang.InterruptedException at java.lang. Object .wait(Native Method) at hudson.remoting.Request.call(Request.java:147) at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:260) ... 42 more possibly related to http://x-stream.github.io/jira/537/ also possibly related seems to be that we got pipeline-maven 3.2.0 installed
            Hide
            markewaite Mark Waite added a comment -

            Is the problem also visible when the agent is running a more current version of Java 8?

            I run Java 8 161 in my tests of agents on Windows 7, Windows 10, CentOS 6, CentOS 7, Debian 8, Debian 9, Ubuntu 14, and Ubuntu 16. I have not seen this failure on any of those machines.

            Show
            markewaite Mark Waite added a comment - Is the problem also visible when the agent is running a more current version of Java 8? I run Java 8 161 in my tests of agents on Windows 7, Windows 10, CentOS 6, CentOS 7, Debian 8, Debian 9, Ubuntu 14, and Ubuntu 16. I have not seen this failure on any of those machines.
            Hide
            markewaite Mark Waite added a comment -

            Fixed in git client plugin 2.7.4 thanks to PR 359 from Vincent Latombe.

            Show
            markewaite Mark Waite added a comment - Fixed in git client plugin 2.7.4 thanks to PR 359 from Vincent Latombe .

              People

              • Assignee:
                Unassigned
                Reporter:
                ssbarnea Sorin Sbarnea
              • Votes:
                1 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: