Perl - awstats.pl config

Veerle nginx-forum at nginx.us
Sun Nov 27 22:37:25 UTC 2011


Hello again, just tried something like that:

  location = /cgi-bin/awstats.pl {
    root /usr/lib/cgi-bin;
    gzip off;
    include /etc/nginx/fastcgi_params;
    fastcgi_pass unix:/var/run/fcgiwrap.socket;
    fastcgi_param SCRIPT_FILENAME /usr/lib/cgi-bin/awstats.pl;       
  }

But i only get a 403 as error.

Error message is:
 *415 FastCGI sent in stderr: "Cannot get script name, is DOCUMENT_ROOT
and SCRIPT_NAME set and is the script executable?" while reading
response header from upstream, client: 80.24.x.x, server: test, request:
"GET /cgi-bin/awstats.pl HTTP/1.1", upstream:
"fastcgi://unix:/var/run/fcgiwrap.socket:",

And why is the root-part needed? SCRIPT_FILENAME is not enough?

Thanks

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,219151,219161#msg-219161



More information about the nginx mailing list