Re: Perl + apache + cgi

[prev] [thread] [next] [Date index for 2004/12/07]

From: Tom Schindl
Subject: Re: Perl + apache + cgi
Date: 13:31 on 07 Dec 2004
Brent Clark wrote:
> Hi
> 
> Would anyone care to share some info on setting up a CGI.
> 
> I keep getting this error:
> 
> [Tue Dec  7 09:48:47 2004] [error] [client 192.168.111.214] Premature
> end of script headers: /home/gevens/cgi-bin/ecco/scripts/agent/logon.pl
> 
> and
> 
> [2004-12-07 10:17:28]: info: (target/actual) uid: (gevens/gevens) gid: 
> (gevens/gevens) cmd: logon.pl
> [2004-12-07 10:17:28]: error: command not in docroot 
> (/home/gevens/cgi-bin/ecco/scripts/agent/logon.pl)
> 
> Here is the permissions of the file in question:
> -rwxr-xr-x  1 gevens gevens   170 Dec  7 12:28 logon.pl
> 
> Here is my apache conf:
> 
> <VirtualHost ftp>

>     DocumentRoot /home/gevens/eccotours
>     ScriptAlias /cgi-bin/ /home/gevens/cgi-bin/
>     AccessFileName a.htaccess
>     User gevens
>     Group gevens
>     ErrorLog /var/log/apache/ecco.log
>     CustomLog /var/log/apache/ecco-access.log common
> </VirtualHost>

Oh. Think now I've got it. You are running into suexec-problems because 
your Root-Apache is running under anonther user than your V-Host-Apache.

Apache is now using suexec to execute your scripts and because your 
script directory is not part of the suexec-path it cannot execute your 
script.

Why do you need to run your scripts as gevens/gevens?

Tom

        -- 
        Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html

Perl + apache + cgi
Brent Clark 12:32 on 07 Dec 2004

Re: Perl + apache + cgi
Tom Schindl 12:42 on 07 Dec 2004

Re: Perl + apache + cgi
Brent Clark 12:48 on 07 Dec 2004

Re: Perl + apache + cgi
Arnaud Blancher 12:46 on 07 Dec 2004

Re: Perl + apache + cgi
Brent Clark 12:54 on 07 Dec 2004

Re: Perl + apache + cgi
Tom Schindl 13:31 on 07 Dec 2004

Re: Perl + apache + cgi
Brent Clark 13:35 on 07 Dec 2004

Re: Perl + apache + cgi
Tom Schindl 14:18 on 07 Dec 2004

Generated at 11:26 on 21 Dec 2004 by mariachi v0.52