CGI scripts not working

Erich Dollansky erichsfreebsdlist at alogt.com
Mon Sep 1 13:54:53 UTC 2014


Hi,

On Mon, 1 Sep 2014 08:55:06 -0400
Monah Baki <monahbaki at gmail.com> wrote:

> Hi all,
> 
> I installed on FreeBSD 9.3 apache 2.4 from ports
> 
> I am trying to run the following test script located in
> /home/ipaudit/public_html/cgi-bin/test
> 
> #!/usr/bin/perl -w
> print "Content-type: text/html\r\n\r\n";
> print "Hello there!<br />\nJust testing .<br />\n";
> for ($i=0; $i<35; $i++)
> {
> print $i."<br />";
> }
> 
> All I get is the script itself and not the output. My httpd-error.log
> shows no error
> 
> 
> 
> Here is what I have in my httpd.conf
> 
> ScriptAlias /cgi-bin/ "/usr/home/ipaudit/public_html/cgi-bin/"
> 
> <Directory "/usr/home/ipaudit/public_html/cgi-bin/">
>     AllowOverride None
> #    Options None
>     Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
>     Order allow,deny
>     Allow from all
>     Require all granted
> </Directory>
> 
>  AddHandler cgi-script .cgi
> 
> ls -la /home/ip[audit/public_html/cgi-bin
> drwxr-xr-x   2 root     wheel     512 Sep  1 07:55 cgi-bin
> 
> and
> 
> -rwxr-xr-x  1 ipaudit  ipaudit    165 Sep  1 08:31 test
> 
> 
> 
> Here is what I have in my httpd-userdir.conf
> 
> UserDir public_html
> 
> <Directory "/home/*/public_html">
>     AllowOverride FileInfo AuthConfig Limit Indexes
>     Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
>     Require method GET POST OPTIONS
> </Directory>
> 
> 
> 
> 
> Am I missing anything else?
> 
maybe this line:

LoadModule cgi_module
libexec/apache22/mod_cgi.so


Erich
> 
> 
> Thanks
> Monah
> _______________________________________________
> freebsd-questions at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe at freebsd.org"



More information about the freebsd-questions mailing list