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

Improve diagnostics: Failed to write into slave jar cache

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major Major
    • remoting
    • None

      Slave got stuck in a state unable to load any classes/resources from master.

      The jar was not written nor the C1 directory was created. I suspect the failure to create directory is silently ignored at https://github.com/jenkinsci/remoting/blob/3622f876e1b1f7548c9e7db0d4d09b76d80c87cc/src/main/java/hudson/remoting/FileSystemJarCache.java#L67

      java.lang.Error: Failed to load resources META-INF/services/org.codehaus.groovy.transform.ASTTransformation
        at hudson.remoting.RemoteClassLoader.findResources(RemoteClassLoader.java:441)
        at java.lang.ClassLoader.getResources(ClassLoader.java:1185)
        at java.lang.ClassLoader.getResources(ClassLoader.java:1181)
        at org.codehaus.groovy.transform.ASTTransformationVisitor.doAddGlobalTransforms(ASTTransformationVisitor.java:194)
        at org.codehaus.groovy.transform.ASTTransformationVisitor.addGlobalTransforms(ASTTransformationVisitor.java:187)
        at org.codehaus.groovy.transform.ASTTransformationVisitor.addPhaseOperations(ASTTransformationVisitor.java:150)
        at org.codehaus.groovy.control.CompilationUnit.<init>(CompilationUnit.java:186)
        at org.codehaus.groovy.control.CompilationUnit.<init>(CompilationUnit.java:118)
        at groovy.lang.GroovyClassLoader.createCompilationUnit(GroovyClassLoader.java:476)
        at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:290)
        at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:281)
        at groovy.lang.GroovyShell.parseClass(GroovyShell.java:731)
        at groovy.lang.GroovyShell.parse(GroovyShell.java:743)
        at groovy.lang.GroovyShell.evaluate(GroovyShell.java:578)
        at groovy.lang.GroovyShell.evaluate(GroovyShell.java:618)
        at groovy.lang.GroovyShell.evaluate(GroovyShell.java:589)
        at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:142)
        at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:114)
        at hudson.remoting.UserRequest.perform(UserRequest.java:121)
        at hudson.remoting.UserRequest.perform(UserRequest.java:49)
        at hudson.remoting.Request$2.run(Request.java:326)
        at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
        at java.util.concurrent.FutureTask.run(FutureTask.java:262)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)
      Caused by: java.util.concurrent.ExecutionException: java.io.IOException: Failed to write to /mnt/hudson_workspace/.slave-jar-cache/C1/0C4793948699B26CD895B765D03C6A.jar
        at hudson.remoting.AsyncFutureImpl.get(AsyncFutureImpl.java:75)
        at hudson.remoting.FutureAdapter.get(FutureAdapter.java:55)
        at hudson.remoting.RemoteClassLoader.findResources(RemoteClassLoader.java:437)
        ... 25 more
      Caused by: java.io.IOException: Failed to write to /mnt/hudson_workspace/.slave-jar-cache/C1/0C4793948699B26CD895B765D03C6A.jar
        at hudson.remoting.FileSystemJarCache.retrieve(FileSystemJarCache.java:112)
        at hudson.remoting.JarCacheSupport$1.run(JarCacheSupport.java:64)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
        at java.util.concurrent.FutureTask.run(FutureTask.java:262)
        at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
        ... 1 more
      Caused by: java.io.IOException: No such file or directory
        at java.io.UnixFileSystem.createFileExclusively(Native Method)
        at java.io.File.createTempFile(File.java:2001)
        at hudson.remoting.FileSystemJarCache.retrieve(FileSystemJarCache.java:69)
        ... 5 more
      

            Unassigned Unassigned
            olivergondza Oliver Gondža
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: