Jenkins slave throws out "Classloading from system classloader disabled" exception

When I run a Maven2 job on a subordinate instance (a wizard on AIX 5.3, subordinate on Windows 2008 (R2)), I get the following message (full stack trace, inserted below): "java.lang.ClassNotFoundException: loading a class from system classloader disabled". This happens with the first job after starting the slave instance (it works as a Windows service). After that, I get "java.lang.NoClassDefFoundError: failed to initialize class error hudson.maven.MavenModuleSetBuild".

If I create a freestyle job and enable the maven command as a batch command to work on a slave, it works fine. It seems like the Maven2 job detects Maven on the slave computer, but apparently it cannot find the maven-plugin (possibly due to a class loading error).

I searched and sent a ticket to jenkins-ci, but so far no luck. Has anyone encountered this problem?

Stacktrace: Found mavenVersion 2.2.1 from file jar:file:/C:/apache-maven-2.2.1/lib/maven-2.2.1-uber.jar!/META-INF/maven/org.apache.maven/maven-core/pom.properties Parsing POMs ERROR: Failed to parse POMs hudson.util.IOException2: remote file operation failed: c:\jenkins-slave\workspace\AO_SISO_AT-smoketest-CIT1 at hudson.remoting.Channel@7b827b82 :10.40.163.105 at hudson.FilePath.act(FilePath.java:752) at hudson.FilePath.act(FilePath.java:738) at hudson.maven.MavenModuleSetBuild$RunnerImpl.parsePoms(MavenModuleSetBuild.java:817) at hudson.maven.MavenModuleSetBuild$RunnerImpl.doRun(MavenModuleSetBuild.java:617) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:429) at hudson.model.Run.run(Run.java:1374) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:467) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:145) Caused by: java.io.IOException: Remote call on 10.40.163.105 failed at hudson.remoting.Channel.call(Channel.java:652) at hudson.FilePath.act(FilePath.java:745) ... 8 more Caused by: java.lang.ExceptionInInitializerError at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1236) at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1110) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:1956) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:270) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at hudson.remoting.Engine$1$1.run(Engine.java:60) at java.lang.Thread.run(Unknown Source) Caused by: com.thoughtworks.xstream.XStream$InitializationException: Could not instantiate converter : com.thoughtworks.xstream.converters.extended.DurationConverter : null at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:735) at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:699) at com.thoughtworks.xstream.XStream.<init>(XStream.java:445) at com.thoughtworks.xstream.XStream.<init>(XStream.java:385) at com.thoughtworks.xstream.XStream.<init>(XStream.java:323) at hudson.util.XStream2.<init>(XStream2.java:62) at hudson.model.Run.<clinit>(Run.java:1867) ... 13 more Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:728) ... 19 more Caused by: javax.xml.datatype.DatatypeConfigurationException: Provider org.apache.xerces.jaxp.datatype.DatatypeFactoryImpl not found at javax.xml.datatype.DatatypeFactory.newInstance(Unknown Source) at com.thoughtworks.xstream.converters.extended.DurationConverter.<init>(DurationConverter.java:33) ... 24 more Caused by: java.lang.ClassNotFoundException: Classloading from system classloader disabled at java.lang.Throwable.<init>(Throwable.java:56) at java.lang.Throwable.<init>(Throwable.java:80) at java.lang.ClassNotFoundException.<init>(ClassNotFoundException.java:80) at hudson.remoting.RemoteClassLoader$ClassLoaderProxy.fetch2(RemoteClassLoader.java:399) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:615) at hudson.remoting.RemoteInvocationHandler$RPCRequest.perform(RemoteInvocationHandler.java:274) at hudson.remoting.Request$2.run(Request.java:270) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:432) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:284) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690) at java.lang.Thread.run(Thread.java:799) 
+4
source share
1 answer

I had a similar problem. Investigated the Internet, but received no solution. Finally debugged jenkins / hudson and solved this problem.

The root cause of this error is that the latest versions of jenkin come with the xml parser in the jenkins.war file. It looks like if your server already has this jar file, it will not allow the jenkin application to reload its own version of xml parsers. Therefore, to solve this problem, I deleted the xercesImpl-2.9.1.jar file from the WEB-INF / lib directory of the jenkins.war file. After that, it replaced the existing war file and restarted the server. And it worked without a problem.

+3
source

All Articles