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

Executing tf using the TFS Plugin throws an IO exception

XMLWordPrintable

      I have added path of tf.cmd in environment vaiables and able to see tf configured in configure systems. Also I am able to execute the tf command in command prompt from path C:\XXX\Jenkins\TEE-CLC-12.0.2 (1)\TEE-CLC-12.0.2(this is the path configured in PATH environment variables). But When i trigger the build then i m getting below error while checking out the source code. Error is
      java.io.IOException: Cannot run program "tf" (in directory "C:\Lakshmi\Jenkins-Workspace\NOVA"): CreateProcess error=2, The system cannot find the file specified
      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:816)
      at hudson.Launcher$ProcStarter.start(Launcher.java:382)
      at hudson.plugins.tfs.TfTool.execute(TfTool.java:101)
      at hudson.plugins.tfs.model.Server.execute(Server.java:121)
      at hudson.plugins.tfs.model.Project.extractChangesetNumber(Project.java:219)
      at hudson.plugins.tfs.model.Project.getRemoteChangesetVersion(Project.java:212)
      at hudson.plugins.tfs.model.Project.getRemoteChangesetVersion(Project.java:235)
      at hudson.plugins.tfs.TeamFoundationServerScm.recordWorkspaceChangesetVersion(TeamFoundationServerScm.java:239)
      at hudson.plugins.tfs.TeamFoundationServerScm.checkout(TeamFoundationServerScm.java:205)
      at hudson.model.AbstractProject.checkout(AbstractProject.java:1282)
      at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610)
      at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532)
      at hudson.model.Run.execute(Run.java:1741)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:98)
      at hudson.model.Executor.run(Executor.java:381)
      Caused by: java.io.IOException: CreateProcess error=2, The system cannot find the file specified
      at java.lang.ProcessImpl.create(Native Method)
      at java.lang.ProcessImpl.<init>(Unknown Source)
      at java.lang.ProcessImpl.start(Unknown Source)
      ... 20 more
      Finished: FAILURE

            laknnna Lakshmi Jaganathan
            laknnna Lakshmi Jaganathan
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: