Welcome! Log In Create A New Profile

Advanced

Re: Perl + fcgi + nginx - what am I doing wrong?

Francis Daly
July 31, 2015 06:24PM
On Fri, Jul 31, 2015 at 02:55:02PM -0400, youradds wrote:

Hi there,

Good that you found and fixed the problem.

> I had:
>
> fastcgi_param SCRIPT_FILENAME
> /srv/www/site.net/www/cgi-bin/$fastcgi_script_name;
>
> but it wasn't in the cgi-bin!!!!It should have been:
>
> fastcgi_param SCRIPT_FILENAME /srv/www/site.net/www/$fastcgi_script_name;
>
> Reboot it, and it works fine now., That'd be whyit was 403'ing... as it
> couldn't find the file. Duh!

Note, you have

try_files $uri =404;
fastcgi_param SCRIPT_FILENAME /srv/www/site.net.net/www/cgi-bin/$fastcgi_script_name;

The first line says "return 404 unless the file $document_root$uri exists".

In general, if the second line does not also refer to exactly the filename
$document_root$uri, you should suspect a problem.

(It can validly refer to a different filename, but probably only where
the fastcgi server is inside a chroot area.)

When you come to use the cgi-bin directory, you'll want to be aware of that.

Cheers,

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Perl + fcgi + nginx - what am I doing wrong?

youradds July 31, 2015 08:55AM

Re: Perl + fcgi + nginx - what am I doing wrong?

youradds July 31, 2015 10:55AM

Re: Perl + fcgi + nginx - what am I doing wrong?

Francis Daly July 31, 2015 12:02PM

Re: Perl + fcgi + nginx - what am I doing wrong?

youradds July 31, 2015 01:51PM

Re: Perl + fcgi + nginx - what am I doing wrong?

Erick Ocrospoma July 31, 2015 02:20PM

Re: Perl + fcgi + nginx - what am I doing wrong?

youradds July 31, 2015 02:55PM

Re: Perl + fcgi + nginx - what am I doing wrong?

youradds July 31, 2015 02:59PM

Re: Perl + fcgi + nginx - what am I doing wrong?

Francis Daly July 31, 2015 06:24PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 306
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready