Home > Blockchain >  Jenkins - Upgrade to Version 2.346.1 from 2.319.1 - Fails to start due to use of ${ITEM_FULLNAME} va
Jenkins - Upgrade to Version 2.346.1 from 2.319.1 - Fails to start due to use of ${ITEM_FULLNAME} va

Time:07-12

After upgrading Jenkins from 2.319 to 2.346, Jenkins fails to start with following error:

    java.nio.file.InvalidPathException: Illegal char <:> at index 87: C:\Users\$DEVTO~1\AppData\Local\Temp\Jenkins-doCheckRawBuildsDir18416011757244540585foo:bar
    at java.base/sun.nio.fs.WindowsPathParser.normalize(WindowsPathParser.java:182)
    at java.base/sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:153)
    at java.base/sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:77)
    at java.base/sun.nio.fs.WindowsPath.parse(WindowsPath.java:92)
    at java.base/sun.nio.fs.WindowsFileSystem.getPath(WindowsFileSystem.java:229)
    at java.base/java.io.File.toPath(File.java:2290)
    at jenkins.model.Jenkins.checkRawBuildsDir(Jenkins.java:3364)
Caused: jenkins.model.InvalidBuildsDir: D:\JenkinsData\jobs\${ITEM_FULLNAME}\builds contains ${ITEM_FULLNAME} but your system does not support it (JENKINS-12251). Use ${ITEM_FULL_NAME} instead
    at jenkins.model.Jenkins.checkRawBuildsDir(Jenkins.java:3366)
    at jenkins.model.Jenkins.loadConfig(Jenkins.java:3300)
Caused: java.io.IOException
    at jenkins.model.Jenkins.loadConfig(Jenkins.java:3303)
    at jenkins.model.Jenkins.access$1200(Jenkins.java:340)
    at jenkins.model.Jenkins$12.run(Jenkins.java:3398)
    at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)
    at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)
    at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)
    at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)
    at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)
    at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
    at java.base/java.lang.Thread.run(Thread.java:834)
Caused: org.jvnet.hudson.reactor.ReactorException
    at org.jvnet.hudson.reactor.Reactor.execute(Reactor.java:291)
    at jenkins.InitReactorRunner.run(InitReactorRunner.java:49)
    at jenkins.model.Jenkins.executeReactor(Jenkins.java:1193)
    at jenkins.model.Jenkins.<init>(Jenkins.java:983)
    at hudson.model.Hudson.<init>(Hudson.java:86)
    at hudson.model.Hudson.<init>(Hudson.java:82)
    at hudson.WebAppMain$3.run(WebAppMain.java:247)
Caused: hudson.util.HudsonFailedToLoad
    at hudson.WebAppMain$3.run(WebAppMain.java:264)

Previous upgrade was done without any issue. I did not find any references in release note about these variables. Also in upgrade guides, no references found about changes related to these variables.

CodePudding user response:

After investigation and checking into the Jenkins code, I found the reason.

in config.xml file I had to change 2 tag's values:

  <workspaceDir>D:\JenkinsData\Workspaces\${ITEM_FULLNAME}</workspaceDir>
  <buildsDir>D:\JenkinsData\jobs\${ITEM_FULLNAME}\builds</buildsDir>

by

  <workspaceDir>D:\JenkinsData\Workspaces\${ITEM_FULL_NAME}</workspaceDir>
  <buildsDir>D:\JenkinsData\jobs\${ITEM_FULL_NAME}\builds</buildsDir>

After this change Jenkins starts without issue.

  • Related