Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Sat Jun 05, 2010 4:09 am 
Offline
Senior Newbie

Joined: Fri Jun 04, 2010 10:47 pm
Posts: 7
Hi guys,

I have got a problem when tring to use nginx+fastcgi.
When i try to access a non-exist .php script, it returns "No input file specified." instead of 404.
Any ideas ?

PS: I followed the guide on
http://library.linode.com/web-servers/n ... 0.04-lucid
PPS: missing static objects are returning normal 404


Top
   
 Post subject:
PostPosted: Sat Jun 05, 2010 6:37 am 
Offline
Senior Member

Joined: Sun Mar 07, 2010 7:47 pm
Posts: 1970
Website: http://www.rwky.net
Location: Earth
No input file specified is an error from PHP, you should get nginx to check if the file exists before passing it to PHP.


Top
   
 Post subject:
PostPosted: Sat Jun 05, 2010 11:44 am 
Offline
Senior Newbie

Joined: Fri Jun 04, 2010 10:47 pm
Posts: 7
turns out a simple set of commands can catch this 404 error

fastcgi_intercept_errors on;
error_page 404 /404.html;


Top
   
 Post subject:
PostPosted: Sat Jun 05, 2010 3:37 pm 
Offline
Senior Member

Joined: Sun Feb 21, 2010 5:12 pm
Posts: 64
Or at the top of the .php location put a
Code:
try_files $uri /404.html;


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group