• Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major Major
    • core
    • None
    • Platform: Sun, OS: Solaris

      The way Hudson launches under JBoss on solaris, the environment variable PATH is
      set to /usr/bin. CVS is installed under /usr/local/bin so Hudson cannot find the
      bin. The solution to this is issue is one of the following

      • make the path to the cvs binary configurable
      • allow the user to pass in a java -D property to specify the path on launch of
        the java container and use that to look for the cvs bin

          [JENKINS-242] Make path to cvs configurable

          poswald created issue -

          Fixed in 1.75.

          Kohsuke Kawaguchi added a comment - Fixed in 1.75.
          Kohsuke Kawaguchi made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

          poswald added a comment -

          Thanks for the enhancement. You got the checkout and that seems to work ok
          (although my server may have died halfway through, I'm still investigating that)
          however, I think you missed the computing changelog part:

          java.io.IOException: cvs: not found
          at
          org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:348)
          at org.apache.tools.ant.taskdefs.AbstractCvsTask.execute(AbstractCvsTask.java:409)
          at
          hudson.org.apache.tools.ant.taskdefs.cvslib.ChangeLogTask.execute(ChangeLogTask.java:281)
          at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:635)
          at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:590)
          at hudson.FilePath.act(FilePath.java:191)
          at hudson.scm.CVSSCM.calcChangeLog(CVSSCM.java:590)
          at hudson.scm.CVSSCM.checkout(CVSSCM.java:230)
          at hudson.model.AbstractProject.checkout(AbstractProject.java:250)
          at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:103)
          at hudson.model.Run.run(Run.java:533)
          at hudson.model.Build.run(Build.java:203)
          at hudson.model.Executor.run(Executor.java:61)
          Caused by: java.io.IOException: cvs: not found
          at java.lang.UNIXProcess.forkAndExec(Native Method)
          at java.lang.UNIXProcess.<init>(UNIXProcess.java:53)
          at java.lang.ProcessImpl.start(ProcessImpl.java:65)
          at java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
          at java.lang.Runtime.exec(Runtime.java:591)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at
          sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:585)
          at
          org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:831)
          at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:436)
          at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:450)
          at
          org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:336)
          ... 12 more
          — Nested Exception —
          java.io.IOException: cvs: not found
          at java.lang.UNIXProcess.forkAndExec(Native Method)
          at java.lang.UNIXProcess.<init>(UNIXProcess.java:53)
          at java.lang.ProcessImpl.start(ProcessImpl.java:65)
          at java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
          at java.lang.Runtime.exec(Runtime.java:591)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at
          sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:585)
          at
          org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:831)
          at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:436)
          at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:450)
          at
          org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:336)
          at org.apache.tools.ant.taskdefs.AbstractCvsTask.execute(AbstractCvsTask.java:409)
          at
          hudson.org.apache.tools.ant.taskdefs.cvslib.ChangeLogTask.execute(ChangeLogTask.java:281)
          at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:635)
          at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:590)
          at hudson.FilePath.act(FilePath.java:191)
          at hudson.scm.CVSSCM.calcChangeLog(CVSSCM.java:590)
          at hudson.scm.CVSSCM.checkout(CVSSCM.java:230)
          at hudson.model.AbstractProject.checkout(AbstractProject.java:250)
          at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:103)
          at hudson.model.Run.run(Run.java:533)
          at hudson.model.Build.run(Build.java:203)
          at hudson.model.Executor.run(Executor.java:61)
          finished: FAILURE

          poswald added a comment - Thanks for the enhancement. You got the checkout and that seems to work ok (although my server may have died halfway through, I'm still investigating that) however, I think you missed the computing changelog part: java.io.IOException: cvs: not found at org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:348) at org.apache.tools.ant.taskdefs.AbstractCvsTask.execute(AbstractCvsTask.java:409) at hudson.org.apache.tools.ant.taskdefs.cvslib.ChangeLogTask.execute(ChangeLogTask.java:281) at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:635) at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:590) at hudson.FilePath.act(FilePath.java:191) at hudson.scm.CVSSCM.calcChangeLog(CVSSCM.java:590) at hudson.scm.CVSSCM.checkout(CVSSCM.java:230) at hudson.model.AbstractProject.checkout(AbstractProject.java:250) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:103) at hudson.model.Run.run(Run.java:533) at hudson.model.Build.run(Build.java:203) at hudson.model.Executor.run(Executor.java:61) Caused by: java.io.IOException: cvs: not found at java.lang.UNIXProcess.forkAndExec(Native Method) at java.lang.UNIXProcess.<init>(UNIXProcess.java:53) at java.lang.ProcessImpl.start(ProcessImpl.java:65) at java.lang.ProcessBuilder.start(ProcessBuilder.java:451) at java.lang.Runtime.exec(Runtime.java:591) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:831) at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:436) at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:450) at org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:336) ... 12 more — Nested Exception — java.io.IOException: cvs: not found at java.lang.UNIXProcess.forkAndExec(Native Method) at java.lang.UNIXProcess.<init>(UNIXProcess.java:53) at java.lang.ProcessImpl.start(ProcessImpl.java:65) at java.lang.ProcessBuilder.start(ProcessBuilder.java:451) at java.lang.Runtime.exec(Runtime.java:591) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:831) at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:436) at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:450) at org.apache.tools.ant.taskdefs.AbstractCvsTask.runCommand(AbstractCvsTask.java:336) at org.apache.tools.ant.taskdefs.AbstractCvsTask.execute(AbstractCvsTask.java:409) at hudson.org.apache.tools.ant.taskdefs.cvslib.ChangeLogTask.execute(ChangeLogTask.java:281) at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:635) at hudson.scm.CVSSCM$4.invoke(CVSSCM.java:590) at hudson.FilePath.act(FilePath.java:191) at hudson.scm.CVSSCM.calcChangeLog(CVSSCM.java:590) at hudson.scm.CVSSCM.checkout(CVSSCM.java:230) at hudson.model.AbstractProject.checkout(AbstractProject.java:250) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:103) at hudson.model.Run.run(Run.java:533) at hudson.model.Build.run(Build.java:203) at hudson.model.Executor.run(Executor.java:61) finished: FAILURE
          poswald made changes -
          Resolution Original: Fixed [ 1 ]
          Status Original: Resolved [ 5 ] New: Reopened [ 4 ]

          Sorry about that. Should be fixed in 1.76.

          You can try the continuous build.

          Kohsuke Kawaguchi added a comment - Sorry about that. Should be fixed in 1.76. You can try the continuous build.
          Kohsuke Kawaguchi made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Reopened [ 4 ] New: Resolved [ 5 ]

          poswald added a comment -

          I've actually figured out how to modify jboss' env variables so this fix is no
          longer strictly necessary for me. The answer was to create a
          PATH=/usr/local/bin:/usr/bin in run.conf and then export PATH in run.sh.

          It is not really ideal to have to modify JBoss's startup scripts since it's
          another thing to forget when moving hudson to a new machine. I also think it may
          be needed for other people since env variables are not considered portable
          across systems in java. Properties are the way you are supposed to pass in
          options to Java. I think the config page is effectively an api between hudson
          and it's environment and therefore any external bin dependencies should go there.

          Thanks for the update, I'll test 1.76 when it's released and let you know if it
          doesn't work.

          poswald added a comment - I've actually figured out how to modify jboss' env variables so this fix is no longer strictly necessary for me. The answer was to create a PATH=/usr/local/bin:/usr/bin in run.conf and then export PATH in run.sh. It is not really ideal to have to modify JBoss's startup scripts since it's another thing to forget when moving hudson to a new machine. I also think it may be needed for other people since env variables are not considered portable across systems in java. Properties are the way you are supposed to pass in options to Java. I think the config page is effectively an api between hudson and it's environment and therefore any external bin dependencies should go there. Thanks for the update, I'll test 1.76 when it's released and let you know if it doesn't work.
          Andrew Bayer made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]

          Mauricio Fenoglio added a comment - - edited

          This is not fixed.

          I have a ubuntu with timezone BRT(jenkins) and a solaris with BRT (cvs) and the update is not syncronized.

          The time is set cvs update -d -r HEAD -D 28 Jun 2012 11:53:50 -0300
          I really cant understand why you dont add an option to conf the -D option ..

          If I cant fix it soon I will have to change to apache C.

          Mauricio Fenoglio added a comment - - edited This is not fixed. I have a ubuntu with timezone BRT(jenkins) and a solaris with BRT (cvs) and the update is not syncronized. The time is set cvs update -d -r HEAD -D 28 Jun 2012 11:53:50 -0300 I really cant understand why you dont add an option to conf the -D option .. If I cant fix it soon I will have to change to apache C.
          Mauricio Fenoglio made changes -
          Resolution Original: Fixed [ 1 ]
          Status Original: Closed [ 6 ] New: Reopened [ 4 ]

            mc1arke Michael Clarke
            poswald poswald
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: