java.io.IOException: error=2, No such file or directory

Jenkins JIRA | woneill | 8 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Using cvs-tag version 1.3 on Hudson 1.282, I'm unable to get the post-build cvs tag to work when it's run on a slave node. It appears to be related to making the tmp directory where the command is executed. The plugin works fine on jobs run on the master node. Some nodes are more verbose than others. This is a quiet node: Executing tag command: cvs -d :pserver:dev@cvs.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121629 foo [hudson132373tmp] $ cvs -d :pserver:dev@cvs.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121629 foo /tmp/hudson132373tmp: No such file or directory FATAL: Perform CVS tagging on succesful build failed. exit code=255 cleaning up /tmp/hudson132373tmp And a more verbose failure on a different node: Executing tag command: cvs -d :pserver:cm@cvscm.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121637 foo [hudson139965tmp] $ cvs -d :pserver:cm@cvscm.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121637 foo ERROR: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory java.io.IOException: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory at java.lang.ProcessBuilder.start(Unknown Source) at hudson.Proc$LocalProc.<init>(Proc.java:127) at hudson.Proc$LocalProc.<init>(Proc.java:105) at hudson.Launcher$LocalLauncher.createLocalProc(Launcher.java:338) at hudson.Launcher$LocalLauncher.launch(Launcher.java:329) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:444) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:428) at hudson.remoting.UserRequest.perform(UserRequest.java:92) at hudson.remoting.UserRequest.perform(UserRequest.java:46) at hudson.remoting.Request$2.run(Request.java:236) 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 java.lang.Thread.run(Unknown Source) Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory at java.lang.UNIXProcess.<init>(Unknown Source) at java.lang.ProcessImpl.start(Unknown Source) ... 16 more IOException occurred: java.io.IOException: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory cleaning up /tmp/hudson139965tmp

    Jenkins JIRA | 8 years ago | woneill
    java.io.IOException: error=2, No such file or directory
  2. 0

    Using cvs-tag version 1.3 on Hudson 1.282, I'm unable to get the post-build cvs tag to work when it's run on a slave node. It appears to be related to making the tmp directory where the command is executed. The plugin works fine on jobs run on the master node. Some nodes are more verbose than others. This is a quiet node: Executing tag command: cvs -d :pserver:dev@cvs.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121629 foo [hudson132373tmp] $ cvs -d :pserver:dev@cvs.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121629 foo /tmp/hudson132373tmp: No such file or directory FATAL: Perform CVS tagging on succesful build failed. exit code=255 cleaning up /tmp/hudson132373tmp And a more verbose failure on a different node: Executing tag command: cvs -d :pserver:cm@cvscm.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121637 foo [hudson139965tmp] $ cvs -d :pserver:cm@cvscm.tek.foo.com:/usr/local/cvsroot rtag -r release-23 TEST-200902121637 foo ERROR: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory java.io.IOException: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory at java.lang.ProcessBuilder.start(Unknown Source) at hudson.Proc$LocalProc.<init>(Proc.java:127) at hudson.Proc$LocalProc.<init>(Proc.java:105) at hudson.Launcher$LocalLauncher.createLocalProc(Launcher.java:338) at hudson.Launcher$LocalLauncher.launch(Launcher.java:329) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:444) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:428) at hudson.remoting.UserRequest.perform(UserRequest.java:92) at hudson.remoting.UserRequest.perform(UserRequest.java:46) at hudson.remoting.Request$2.run(Request.java:236) 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 java.lang.Thread.run(Unknown Source) Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory at java.lang.UNIXProcess.<init>(Unknown Source) at java.lang.ProcessImpl.start(Unknown Source) ... 16 more IOException occurred: java.io.IOException: Cannot run program "cvs" (in directory "/tmp/hudson139965tmp"): java.io.IOException: error=2, No such file or directory cleaning up /tmp/hudson139965tmp

    Jenkins JIRA | 8 years ago | woneill
    java.io.IOException: error=2, No such file or directory
  3. 0

    When trying to execute Maven 2 executable on slave node from a build configured as "free-style software project" and a build step of type "Invoke top-level Maven targets" it cannot find mvn executable: Started by user krystian.nowak Building remotely on slave01.myorg.org Updating https://svn.myorg.org/trunk At revision 35030 no change for https://svn.myorg.org/trunk since the previous build [ant] $ ant -file build.xml Buildfile: build.xml update-settings: [copy] Copying 1 file to /home/tomcat/.hudson/workspace/common-resources-public BUILD SUCCESSFUL Total time: 0 seconds [trunk] $ mvn -f java/pom.xml clean install FATAL: command execution failed java.io.IOException: Cannot run program "mvn" (in directory "/home/tomcat/.hudson/workspace/common-resources-public/trunk"): java.io.IOException: error=2, No such file or directory at java.lang.ProcessBuilder.start(ProcessBuilder.java:459) at hudson.Proc$LocalProc.<init>(Proc.java:132) at hudson.Proc$LocalProc.<init>(Proc.java:110) at hudson.Launcher$LocalLauncher.createLocalProc(Launcher.java:359) at hudson.Launcher$LocalLauncher.launch(Launcher.java:342) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:501) at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:485) at hudson.remoting.UserRequest.perform(UserRequest.java:92) at hudson.remoting.UserRequest.perform(UserRequest.java:46) at hudson.remoting.Request$2.run(Request.java:236) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory at java.lang.UNIXProcess.<init>(UNIXProcess.java:148) at java.lang.ProcessImpl.start(ProcessImpl.java:65) at java.lang.ProcessBuilder.start(ProcessBuilder.java:452) ... 15 more Recording test results Sending e-mails to: failures@myorg.org Finished: FAILURE It does not happen if it is built on master node. It does not occur for "maven2 project" type. On slave node mvn is in exactly the same place as on master node: [tomcat@slave01 ~]$ which mvn /usr/local/maven/bin/mvn [tomcat@master ~]$ which mvn /usr/local/maven/bin/mvn Top level Maven 2 configuration is: Maven installation: name: 2.0 MAVEN_HOME: /usr/local/maven Hudson ver. 1.297 Maven Integration plugin ver. 1.297 Hudson SSH Slaves plugin ver. 0.4 (Launch method: Launch slave agents on Linux machines via SSH)

    Jenkins JIRA | 8 years ago | Krystian Nowak
    java.io.IOException: error=2, No such file or directory
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    How can I use an alternate path for a Jenkins slave SCM step (CVS)

    Google Groups | 6 years ago | Matthew Johnson
    java.io.IOException: cvs: not found
  6. 0

    java.io.IOException: Cannot run program "ant" - java pressing answers

    itanswerz.com | 2 years ago
    java.io.IOException: Cannot run program "ant" (in directory "/hudson/buildTool/src/bt"): error=2, No existe el fichero o el directorio

  1. rp 1 times, last 4 months ago
  2. michallos 1 times, last 5 months ago
  3. eti22 1 times, last 6 months ago
  4. asdasd 24 times, last 7 months ago
  5. rexgreenza 8 times, last 7 months ago
2 more registered users
93 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.io.IOException

    java.io.IOException: error=2, No such file or directory

    at java.lang.UNIXProcess.<init>()
  2. Java RT
    ProcessBuilder.start
    1. java.lang.UNIXProcess.<init>(Unknown Source)
    2. java.lang.ProcessImpl.start(Unknown Source)
    3. java.lang.ProcessBuilder.start(Unknown Source)
    3 frames
  3. Hudson
    Launcher$RemoteLaunchCallable.call
    1. hudson.Proc$LocalProc.<init>(Proc.java:127)
    2. hudson.Proc$LocalProc.<init>(Proc.java:105)
    3. hudson.Launcher$LocalLauncher.createLocalProc(Launcher.java:338)
    4. hudson.Launcher$LocalLauncher.launch(Launcher.java:329)
    5. hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:444)
    6. hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:428)
    6 frames
  4. Hudson :: Remoting Layer
    Request$2.run
    1. hudson.remoting.UserRequest.perform(UserRequest.java:92)
    2. hudson.remoting.UserRequest.perform(UserRequest.java:46)
    3. hudson.remoting.Request$2.run(Request.java:236)
    3 frames
  5. Java RT
    Thread.run
    1. java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    2. java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
    3. java.util.concurrent.FutureTask.run(Unknown Source)
    4. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
    5. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    6. java.lang.Thread.run(Unknown Source)
    6 frames