tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Januski, Ken" <kjanu...@phillynews.com>
Subject RE: Can Tomcat really run cgi scripts?
Date Tue, 02 Dec 2003 20:21:09 GMT
Beat my head against wall for another couple hours and still end up with
this error. Anyone have any other ideas?

java.io.IOException: CreateProcess: perl
C:\Tomcat4112\webapps\examples\WEB-INF\cgi\exp.pl lname=januski fname=ken
error=2
	at java.lang.Win32Process.create(Native Method)
	at java.lang.Win32Process.(Win32Process.java:63)
	at java.lang.Runtime.execInternal(Native Method)
	at java.lang.Runtime.exec(Runtime.java:550)
	at java.lang.Runtime.exec(Runtime.java:416)
	at
org.apache.catalina.servlets.CGIServlet$CGIRunner.run(CGIServlet.java:1583)
	at
org.apache.catalina.servlets.CGIServlet.doGet(CGIServlet.java:635)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:247)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:193)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:260)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:191)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
	at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
.java:471)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2396)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
	at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
java:170)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172
)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:174)
	at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at
org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
	at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:405)
	at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
ction(Http11Protocol.java:380)
	at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:508)
	at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:533)
	at java.lang.Thread.run(Thread.java:536)


-----Original Message-----
From: Januski, Ken [mailto:kjanuski@phillynews.com]
Sent: Tuesday, December 02, 2003 1:01 PM
To: Tomcat Users List
Subject: RE: Can Tomcat really run cgi scripts?


Thanks Chris,

I've tried "!#c:\perl\bin\perl.exe", "#!c:\perl\bin", "#!perl", and
"#!/usr/bin/perl" and get same error on each. I've also added perl to the
path environmental PATH variable. I do think that you're right about missing
PATH information so I'll keep experimenting. I just can't figure out what
additional paths to try.

Ken

-----Original Message-----
From: Christopher Schultz [mailto:christopher.d.schultz@comcast.net]
Sent: Tuesday, December 02, 2003 12:53 PM
To: Tomcat Users List
Subject: Re: Can Tomcat really run cgi scripts?


Ken,

 > But now I'm stuck with this error:
> java.io.IOException: CreateProcess: perl
> C:\Tomcat4112\webapps\examples\WEB-INF\cgi\exp.cgi

This is likely to be due to the lack of PATH information available to 
the script itself. Try using #!/usr/bin/perl in your script instead of 
#!perl

I've heard some complains about sub-process permissions, but my initial 
reaction is that they are errant complaints.

-chris


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message