• Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Blocker Blocker
    • core
    • None
    • 1.600

      After updating from 1.599 to 1.600 no ant build works anymore with the following stack, Let me know if any additional information is required.

      Reverting to 1.599 resolves the issue.

      [Common_Restore] $ cmd.exe /C '"ant.bat -file build.xml -Djenkins.managed=true -DjarOutputDir=C:\jenkins\workspace\12_Common_Restore/workspace -DarchiveDir=C:\jenkins\workspace\12_Common_Restore/archive -DPROJECTS_SRC=C:\jenkins\workspace\12_Common_Restore -DPROJECTS_LIB=C:\jenkins\workspace\Common_Libs\lib && exit %%ERRORLEVEL%%"'
      The filename or extension is too long
      FATAL: command execution failed.Maybe you need to configure the job to choose one of your Ant installations?
      java.io.IOException: Cannot run program "cmd.exe" (in directory "C:\jenkins\workspace\12_Common_Restore\build\Common_Restore"): CreateProcess error=206, The filename or extension is too long
      	at java.lang.ProcessBuilder.start(Unknown Source)
      	at hudson.Proc$LocalProc.<init>(Proc.java:244)
      	at hudson.Proc$LocalProc.<init>(Proc.java:216)
      	at hudson.Launcher$LocalLauncher.launch(Launcher.java:803)
      	at hudson.Launcher$ProcStarter.start(Launcher.java:381)
      	at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:1136)
      	at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:1101)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:118)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:48)
      	at hudson.remoting.Request$2.run(Request.java:328)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at hudson.remoting.Engine$1$1.run(Engine.java:63)
      	at java.lang.Thread.run(Unknown Source)
      	at ......remote call to WINDOWS-AQGP48S-87.244(Native Method)
      	at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1356)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:221)
      	at hudson.remoting.Channel.call(Channel.java:752)
      	at hudson.Launcher$RemoteLauncher.launch(Launcher.java:916)
      	at hudson.Launcher$ProcStarter.start(Launcher.java:381)
      	at hudson.Launcher$ProcStarter.join(Launcher.java:388)
      	at hudson.tasks.Ant.perform(Ant.java:217)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:761)
      	at hudson.model.Build$BuildExecution.build(Build.java:203)
      	at hudson.model.Build$BuildExecution.doRun(Build.java:160)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:536)
      	at hudson.model.Run.execute(Run.java:1717)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      	at hudson.model.ResourceController.execute(ResourceController.java:89)
      	at hudson.model.Executor.run(Executor.java:240)
      Caused by: java.io.IOException: CreateProcess error=206, The filename or extension is too long
      	at java.lang.ProcessImpl.create(Native Method)
      	at java.lang.ProcessImpl.<init>(Unknown Source)
      	at java.lang.ProcessImpl.start(Unknown Source)
      	at java.lang.ProcessBuilder.start(Unknown Source)
      	at hudson.Proc$LocalProc.<init>(Proc.java:244)
      	at hudson.Proc$LocalProc.<init>(Proc.java:216)
      	at hudson.Launcher$LocalLauncher.launch(Launcher.java:803)
      	at hudson.Launcher$ProcStarter.start(Launcher.java:381)
      	at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:1136)
      	at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:1101)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:118)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:48)
      	at hudson.remoting.Request$2.run(Request.java:328)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at hudson.remoting.Engine$1$1.run(Engine.java:63)
      	at java.lang.Thread.run(Unknown Source)
      Build step 'Invoke Ant' marked build as failure
      

          [JENKINS-27199] Invoke Ant fails in 1.600

          Daniel Beck added a comment -

          Is this the same command line as provided in the log when building on Jenkins 1.599?

          Daniel Beck added a comment - Is this the same command line as provided in the log when building on Jenkins 1.599?

          Andrew Kujtan added a comment -

          Yes, projects were not modified at all, 1.599 included below,

          [Common_Restore] $ cmd.exe /C '"ant.bat -file build.xml -Djenkins.managed=true -DjarOutputDir=C:\jenkins\workspace\12_Common_Restore/workspace -DarchiveDir=C:\jenkins\workspace\12_Common_Restore/archive -DPROJECTS_SRC=C:\jenkins\workspace\12_Common_Restore -DPROJECTS_LIB=C:\jenkins\workspace\Common_Libs\lib && exit %%ERRORLEVEL%%"'
          Buildfile: C:\jenkins\workspace\12_Common_Restore\build\Common_Restore\build.xml

          Andrew Kujtan added a comment - Yes, projects were not modified at all, 1.599 included below, [Common_Restore] $ cmd.exe /C '"ant.bat -file build.xml -Djenkins.managed=true -DjarOutputDir=C:\jenkins\workspace\12_Common_Restore/workspace -DarchiveDir=C:\jenkins\workspace\12_Common_Restore/archive -DPROJECTS_SRC=C:\jenkins\workspace\12_Common_Restore -DPROJECTS_LIB=C:\jenkins\workspace\Common_Libs\lib && exit %%ERRORLEVEL%%"' Buildfile: C:\jenkins\workspace\12_Common_Restore\build\Common_Restore\build.xml

          Chris Sullens added a comment -

          Same sort of error on all of my linux jobs (my 1 windows job is ok).
          No changes to the project, just started failing after 1.600 update.

          For example:
          14:47:00 Started by timer
          14:47:00 [EnvInject] - Loading node environment variables.
          14:47:00 Building on master in workspace /var/lib/jenkins/jobs/Remove Empty Folders - SEALSBUNTU - sabnzbd/workspace
          14:47:00 $ hg --config auth.jenkins.prefix=* --config ******** --config ******** --config "auth.jenkins.schemes=http https" clone --rev default --noupdate http://sealsbuntu:5000/Jenkins-Repo "/var/lib/jenkins/jobs/Remove Empty Folders - SEALSBUNTU - sabnzbd/workspace"
          14:47:00 ERROR: Failed to clone http://sealsbuntu:5000/Jenkins-Repo
          14:47:00 java.io.IOException: Cannot run program "hg": error=7, Argument list too long
          14:47:00 at java.lang.ProcessBuilder.start(ProcessBuilder.java:1047)
          14:47:00 at hudson.Proc$LocalProc.<init>(Proc.java:244)
          14:47:00 at hudson.Proc$LocalProc.<init>(Proc.java:216)
          14:47:00 at hudson.Launcher$LocalLauncher.launch(Launcher.java:803)
          14:47:00 at hudson.Launcher$ProcStarter.start(Launcher.java:381)
          14:47:00 at hudson.Launcher$ProcStarter.join(Launcher.java:388)
          14:47:00 at hudson.plugins.mercurial.MercurialSCM.clone(MercurialSCM.java:779)
          14:47:00 at hudson.plugins.mercurial.MercurialSCM.checkout(MercurialSCM.java:547)
          14:47:00 at hudson.scm.SCM.checkout(SCM.java:484)
          14:47:00 at hudson.model.AbstractProject.checkout(AbstractProject.java:1270)
          14:47:00 at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:609)
          14:47:00 at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
          14:47:00 at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531)
          14:47:00 at hudson.model.Run.execute(Run.java:1717)
          14:47:00 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
          14:47:00 at hudson.model.ResourceController.execute(ResourceController.java:89)
          14:47:00 at hudson.model.Executor.run(Executor.java:240)
          14:47:00 Caused by: java.io.IOException: error=7, Argument list too long
          14:47:00 at java.lang.UNIXProcess.forkAndExec(Native Method)
          14:47:00 at java.lang.UNIXProcess.<init>(UNIXProcess.java:186)
          14:47:00 at java.lang.ProcessImpl.start(ProcessImpl.java:130)
          14:47:00 at java.lang.ProcessBuilder.start(ProcessBuilder.java:1028)
          14:47:00 ... 16 more
          14:47:00 ERROR: Failed to clone http://sealsbuntu:5000/Jenkins-Repo
          14:47:00 [BFA] Scanning build for known causes...
          14:47:00
          14:47:00 [BFA] Done. 0s
          14:47:00 Collecting metadata...
          14:47:00 Metadata collection done.
          14:47:00 Started calculate disk usage of build
          14:47:00 Finished Calculation of disk usage of build in 0 seconds
          14:47:00 Started calculate disk usage of workspace
          14:47:00 Finished Calculation of disk usage of workspace in 0 seconds
          14:47:00 Finished: FAILURE

          Chris Sullens added a comment - Same sort of error on all of my linux jobs (my 1 windows job is ok). No changes to the project, just started failing after 1.600 update. For example: 14:47:00 Started by timer 14:47:00 [EnvInject] - Loading node environment variables. 14:47:00 Building on master in workspace /var/lib/jenkins/jobs/Remove Empty Folders - SEALSBUNTU - sabnzbd/workspace 14:47:00 $ hg --config auth.jenkins.prefix=* --config ******** --config ******** --config "auth.jenkins.schemes=http https" clone --rev default --noupdate http://sealsbuntu:5000/Jenkins-Repo "/var/lib/jenkins/jobs/Remove Empty Folders - SEALSBUNTU - sabnzbd/workspace" 14:47:00 ERROR: Failed to clone http://sealsbuntu:5000/Jenkins-Repo 14:47:00 java.io.IOException: Cannot run program "hg": error=7, Argument list too long 14:47:00 at java.lang.ProcessBuilder.start(ProcessBuilder.java:1047) 14:47:00 at hudson.Proc$LocalProc.<init>(Proc.java:244) 14:47:00 at hudson.Proc$LocalProc.<init>(Proc.java:216) 14:47:00 at hudson.Launcher$LocalLauncher.launch(Launcher.java:803) 14:47:00 at hudson.Launcher$ProcStarter.start(Launcher.java:381) 14:47:00 at hudson.Launcher$ProcStarter.join(Launcher.java:388) 14:47:00 at hudson.plugins.mercurial.MercurialSCM.clone(MercurialSCM.java:779) 14:47:00 at hudson.plugins.mercurial.MercurialSCM.checkout(MercurialSCM.java:547) 14:47:00 at hudson.scm.SCM.checkout(SCM.java:484) 14:47:00 at hudson.model.AbstractProject.checkout(AbstractProject.java:1270) 14:47:00 at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:609) 14:47:00 at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) 14:47:00 at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531) 14:47:00 at hudson.model.Run.execute(Run.java:1717) 14:47:00 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 14:47:00 at hudson.model.ResourceController.execute(ResourceController.java:89) 14:47:00 at hudson.model.Executor.run(Executor.java:240) 14:47:00 Caused by: java.io.IOException: error=7, Argument list too long 14:47:00 at java.lang.UNIXProcess.forkAndExec(Native Method) 14:47:00 at java.lang.UNIXProcess.<init>(UNIXProcess.java:186) 14:47:00 at java.lang.ProcessImpl.start(ProcessImpl.java:130) 14:47:00 at java.lang.ProcessBuilder.start(ProcessBuilder.java:1028) 14:47:00 ... 16 more 14:47:00 ERROR: Failed to clone http://sealsbuntu:5000/Jenkins-Repo 14:47:00 [BFA] Scanning build for known causes... 14:47:00 14:47:00 [BFA] Done. 0s 14:47:00 Collecting metadata... 14:47:00 Metadata collection done. 14:47:00 Started calculate disk usage of build 14:47:00 Finished Calculation of disk usage of build in 0 seconds 14:47:00 Started calculate disk usage of workspace 14:47:00 Finished Calculation of disk usage of workspace in 0 seconds 14:47:00 Finished: FAILURE

          Daniel Beck added a comment -

          Would be interesting if any of you could test the build (or build from my branch) that fixes JENKINS-27178 to see whether this is related. I cannot see any other related changes in the source code. At least seals also has env-inject installed.

          Daniel Beck added a comment - Would be interesting if any of you could test the build (or build from my branch) that fixes JENKINS-27178 to see whether this is related. I cannot see any other related changes in the source code. At least seals also has env-inject installed.

          Chris Sullens added a comment -

          I'd be happy to test...my server is ubuntu, if you could point me to a download I'll give it a shot

          Chris Sullens added a comment - I'd be happy to test...my server is ubuntu, if you could point me to a download I'll give it a shot

          Daniel Beck added a comment -

          In the comments to JENKINS-27178 I link to a jenkins war on my Dropbox. I also link to a Github branch with a fix so you could build it yourself.

          Daniel Beck added a comment - In the comments to JENKINS-27178 I link to a jenkins war on my Dropbox. I also link to a Github branch with a fix so you could build it yourself.

          Chris Sullens added a comment -

          the dropbox war fixed my problem...the jobs are successful again. thanks for the help!

          Chris Sullens added a comment - the dropbox war fixed my problem...the jobs are successful again. thanks for the help!

          For the reference: Last night we got a similar exception as below ("error=7, Argument list too long"), without any human interference and/or any OS/jenkins updates happening automatically. Jenkins 1.600 on ubuntu, plugin EnvInject not installed. All git-based jobs failed thereafter. One of our jobs that runs every 5 minutes worked fine half of the night, then failed consistently during the rest of the night. Restarting jenkins 1.600 fixed the problem. Will upgrade to 1.602 which will hopefully prevent the problem in the future.

          [...]
          ERROR: Workspace has a .git repository, but it appears to be corrupt.
          hudson.plugins.git.GitException: Error performing command: git rev-parse --is-inside-work-tree
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1598)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1567)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1563)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1249)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1261)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.hasGitRepo(CliGitAPIImpl.java:216)
          	at hudson.plugins.git.GitAPI.hasGitRepo(GitAPI.java:232)
          	at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:927)
          	at hudson.plugins.git.GitSCM.checkout(GitSCM.java:984)
          	at hudson.scm.SCM.checkout(SCM.java:484)
          	at hudson.model.AbstractProject.checkout(AbstractProject.java:1270)
          	at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:609)
          	at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
          	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531)
          	at hudson.model.Run.execute(Run.java:1717)
          	at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:531)
          	at hudson.model.ResourceController.execute(ResourceController.java:89)
          	at hudson.model.Executor.run(Executor.java:240)
          Caused by: java.io.IOException: Cannot run program "git" (in directory "/var/lib/jenkins/jobs/<MYJOBNAME>/workspace"): error=7, Argument list too long
          	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
          	at hudson.Proc$LocalProc.<init>(Proc.java:244)
          	at hudson.Proc$LocalProc.<init>(Proc.java:216)
          	at hudson.Launcher$LocalLauncher.launch(Launcher.java:803)
          	at hudson.Launcher$ProcStarter.start(Launcher.java:381)
          	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1587)
          	... 17 more
          Caused by: java.io.IOException: error=7, Argument list too long
          	at java.lang.UNIXProcess.forkAndExec(Native Method)
          	at java.lang.UNIXProcess.<init>(UNIXProcess.java:187)
          	at java.lang.ProcessImpl.start(ProcessImpl.java:134)
          	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
          	... 22 more
          Cloning the remote Git repository
          [...]
          

          Stefan Thurnherr added a comment - For the reference: Last night we got a similar exception as below ("error=7, Argument list too long"), without any human interference and/or any OS/jenkins updates happening automatically. Jenkins 1.600 on ubuntu, plugin EnvInject not installed. All git-based jobs failed thereafter. One of our jobs that runs every 5 minutes worked fine half of the night, then failed consistently during the rest of the night. Restarting jenkins 1.600 fixed the problem. Will upgrade to 1.602 which will hopefully prevent the problem in the future. [...] ERROR: Workspace has a .git repository, but it appears to be corrupt. hudson.plugins.git.GitException: Error performing command: git rev-parse --is-inside-work-tree at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1598) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1567) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1563) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1249) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1261) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.hasGitRepo(CliGitAPIImpl.java:216) at hudson.plugins.git.GitAPI.hasGitRepo(GitAPI.java:232) at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:927) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:984) at hudson.scm.SCM.checkout(SCM.java:484) at hudson.model.AbstractProject.checkout(AbstractProject.java:1270) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:609) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531) at hudson.model.Run.execute(Run.java:1717) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:531) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) Caused by: java.io.IOException: Cannot run program "git" (in directory "/var/lib/jenkins/jobs/<MYJOBNAME>/workspace"): error=7, Argument list too long at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048) at hudson.Proc$LocalProc.<init>(Proc.java:244) at hudson.Proc$LocalProc.<init>(Proc.java:216) at hudson.Launcher$LocalLauncher.launch(Launcher.java:803) at hudson.Launcher$ProcStarter.start(Launcher.java:381) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1587) ... 17 more Caused by: java.io.IOException: error=7, Argument list too long at java.lang.UNIXProcess.forkAndExec(Native Method) at java.lang.UNIXProcess.<init>(UNIXProcess.java:187) at java.lang.ProcessImpl.start(ProcessImpl.java:134) at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029) ... 22 more Cloning the remote Git repository [...]

            Unassigned Unassigned
            andrewk Andrew Kujtan
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: