IOException if cvs not in path

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

IOException if cvs not in path

paul oswald
Hey! I'm back. I've had some success testing Hudson out and I'm now looking to move it into our normal build process now. After helping me get my problem solved on windows I'm having the same problem on Solaris: https://hudson.dev.java.net/servlets/ReadMsg?listName=users&msgNo=188

This time I am using version 1.73 on Solaris and trying to deploy Hudson under JBoss 4.0.4.GA. The issue seems to be that the cvs bin is not found. Now I know from last time that you agree that unhandled exceptions are a bad thing so I'd like to report that first of all. On our solaris install cvs is in /usr/local/bin and we cannot move or link it to /usr/bin since this is a read only filesystem. When I click on the link to check the cvs version I get the exception below. I am starting JBoss with /usr/local/bin in the PATH and have tied adding it as a -DPATH=/usr/local/bin as well as with - Djava.library.path=/usr/local/bin and even though those get picked up, the environment variable page still says: PATH  /usr/bin:

Any ideas for me? I cant seem to get this to see cvs no matter what I try. The exception I'm seeing is below

-Paul

HTTP Status 500 -


type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: cvs: not found
org.kohsuke.stapler.Stapler.invoke(Stapler.java:233)
org.kohsuke.stapler.MetaClass$9.doDispatch(MetaClass.java:207)
org.kohsuke.stapler.NameBasedDispatcher.dispatch (NameBasedDispatcher.java:30)
org.kohsuke.stapler.Stapler.invoke(Stapler.java:224)
org.kohsuke.stapler.Stapler.invoke(Stapler.java:169)
org.kohsuke.stapler.Stapler.service(Stapler.java:68)
javax.servlet.http.HttpServlet.service (HttpServlet.java:810)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

root cause

java.io.IOException: cvs: not found
java.lang.UNIXProcess.forkAndExec (Native Method)
java.lang.UNIXProcess.<init>(UNIXProcess.java:53)
java.lang.ProcessImpl.start(ProcessImpl.java:65)
java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
java.lang.Runtime.exec(Runtime.java :591)
hudson.Proc$LocalProc.<init>(Proc.java:79)
hudson.Launcher$LocalLauncher.launch(Launcher.java:130)
hudson.Launcher.launch(Launcher.java:74)
hudson.scm.CVSSCM$DescriptorImpl.doVersion(CVSSCM.java :779)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java :25)
java.lang.reflect.Method.invoke(Method.java:585)
org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:50)
org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:59)
org.kohsuke.stapler.NameBasedDispatcher.dispatch (NameBasedDispatcher.java:30)
org.kohsuke.stapler.Stapler.invoke(Stapler.java:224)
org.kohsuke.stapler.MetaClass$9.doDispatch(MetaClass.java:207)
org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java :30)
org.kohsuke.stapler.Stapler.invoke(Stapler.java:224)
org.kohsuke.stapler.Stapler.invoke(Stapler.java:169)
org.kohsuke.stapler.Stapler.service(Stapler.java:68)
javax.servlet.http.HttpServlet.service(HttpServlet.java :810)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

note The full stack trace of the root cause is available in the Apache Tomcat/5.5.17 logs.


Apache Tomcat/5.5.17



Reply | Threaded
Open this post in threaded view
|

Re: IOException if cvs not in path

Kohsuke Kawaguchi-2
Paul Oswald wrote:
> Hey! I'm back. I've had some success testing Hudson out and I'm now looking
> to move it into our normal build process now. After helping me get my
> problem solved on windows I'm having the same problem on Solaris:
> https://hudson.dev.java.net/servlets/ReadMsg?listName=users&msgNo=188
>
> This time I am using version 1.73 on Solaris and trying to deploy Hudson
> under JBoss 4.0.4.GA. The issue seems to be that the cvs bin is not found.
> Now I know from last time that you agree that unhandled exceptions are a bad
> thing so I'd like to report that first of all.

Thanks. If you can file this as an issue, that would be superb.

 > On our solaris install cvs is
> in /usr/local/bin and we cannot move or link it to /usr/bin since this is a
> read only filesystem. When I click on the link to check the cvs version I
> get the exception below. I am starting JBoss with /usr/local/bin in the PATH
> and have tied adding it as a -DPATH=/usr/local/bin as well as with -
> Djava.library.path=/usr/local/bin and even though those get picked up, the
> environment variable page still says: PATH  /usr/bin:

I suspect this is a JBoss issue --- maybe they have some weird launch
sequence that inherits environment variables from somewhere else.


> Any ideas for me? I cant seem to get this to see cvs no matter what I try.
> The exception I'm seeing is below

I think another RFE is in order. Allow cvs executable location to be
configured via Hudson UI.

--
Kohsuke Kawaguchi
Sun Microsystems                   [hidden email]

smime.p7s (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: IOException if cvs not in path

paul oswald
In reply to this post by paul oswald
FYI I created 3 new issues:

https://hudson.dev.java.net/issues/show_bug.cgi?id=241 (exception in when checking version)
https://hudson.dev.java.net/issues/show_bug.cgi?id=242 (need a configurable cvs location)
https://hudson.dev.java.net/issues/show_bug.cgi?id=243 (a separate issue regarding ant on solaris)

Thanks!
Reply | Threaded
Open this post in threaded view
|

Re: IOException if cvs not in path

Kohsuke Kawaguchi-2
Paul Oswald wrote:
> FYI I created 3 new issues:
>
> https://hudson.dev.java.net/issues/show_bug.cgi?id=241 (exception in when
> checking version)
> https://hudson.dev.java.net/issues/show_bug.cgi?id=242 (need a configurable
> cvs location)
> https://hudson.dev.java.net/issues/show_bug.cgi?id=243 (a separate issue
> regarding ant on solaris)

Thanks. I'll take a look, and you'll know when it's fixed.

--
Kohsuke Kawaguchi
Sun Microsystems                   [hidden email]

smime.p7s (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: IOException if cvs not in path

sjoerdbakker
Wouldn't it be useful to get the cvs path (as well as the shell path) to be
configurable per slave?

I can imagine a situation where you want to run your master on a Linux box,
when you want to run the slave on Solaris?

Sjoerd

----- Original Message -----
From: "Kohsuke Kawaguchi" <[hidden email]>
To: <[hidden email]>
Sent: Saturday, January 20, 2007 12:44 AM
Subject: Re: IOException if cvs not in path


> Paul Oswald wrote:
>> FYI I created 3 new issues:
>>
>> https://hudson.dev.java.net/issues/show_bug.cgi?id=241 (exception in when
>> checking version)
>> https://hudson.dev.java.net/issues/show_bug.cgi?id=242 (need a
>> configurable
>> cvs location)
>> https://hudson.dev.java.net/issues/show_bug.cgi?id=243 (a separate issue
>> regarding ant on solaris)
>
> Thanks. I'll take a look, and you'll know when it's fixed.
>
> --
> Kohsuke Kawaguchi
> Sun Microsystems                   [hidden email]
>

smime.p7s (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Re: IOException if cvs not in path

Kohsuke Kawaguchi-2
Sjoerd Bakker wrote:
> Wouldn't it be useful to get the cvs path (as well as the shell path) to be
> configurable per slave?
>
> I can imagine a situation where you want to run your master on a Linux box,
> when you want to run the slave on Solaris?

Yes. The same applies to everything --- JDK path, Ant path, Maven path,
etc. So it really needs a bit of generalization. Doing it without
cluttering the UI would be a challenge though.

The other thing is that once you have a certain number of slaves, it no
longer makes much sense to have individual slaves so different, because
it would be harder to maintain. You typically ends up making slaves
fairly uniform. At least that's what I do.

So that's probably why I didn't need this feature so far.

For now, I recommend you configure each slaves with symlinks to their
actual tools. like,

/export/home/hudson/bin
    cvs -> /usr/local/bin/cvs
    svn -> /bin/svn
    ...

etc.

--
Kohsuke Kawaguchi
Sun Microsystems                   [hidden email]

smime.p7s (4K) Download Attachment