Wrox Programmer Forums
Beginning PHP Beginning-level PHP discussions. More advanced coders should post to the Pro PHP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning PHP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old December 16th, 2004, 02:19 PM
Registered User
Join Date: Dec 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default CGI Timeout

I've been trying to figure this one out for a few days now.

I just moved all my web sites to a new server. I am running IIS4 on a Windows 2000 server. I have installed php 4.3.10. The database is MySQL.

The problem I am running into, is I am getting a CGI timeout whenever I try to go to a certain page (2 pages actually).

The database connection appears to work fine (since the html itself is actually in the mysql database) and the sessions are getting created in my \sessiondata folder.

This site has worked fine for about a year on the old server, and is still up and running fine right now. I have gone through every single tiny little setting I could think of in the Windows registry, IIS, and php.ini and they are all the same on both machines.

I have been googling on this for a day, and everything anyone has mentioned I have already looked at and tried. :(

The I_User has access (of course) to the proper folders.
The timeouts set in IIS and php.ini are set correctly (this should only take a quarter second anyway...it's a very tiny page).
Same version of IIS.
Same operating system version with the same patches/service packs.
Same version of PHP
Same version of MySQL
.php is in the configuration of IIS to go to D:\php\php.exe

All these settings are exactly the same as they are on the old server down to the environment variables minus the computer name of course.

All the other php pages on the (new) site work fine. The only difference is that the 2 pages that don't are processing a form submission.

It's driving me crazy since everything is exactly the same between the two servers, but these 2 pages on the new server just refuse to work. :(

Old December 20th, 2004, 04:09 PM
Authorized User
Join Date: Dec 2004
Posts: 53
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to peg110

Great.... Everything is the same on the old and new.... We got that. But I think a bit more information is needed.

First of all what is the EXACT wording of the error message?
Second Why are you using the CGI? I know PHP has the capability of running through CGI (or something like that) but everything I read says that that is a BAD choice.

Finally a bit more information would be helpful. Perhaps a code snippit of where you think the problem might be.

Paul Gardner
Via Web @ http://www.mnetweb.co.uk/irc
Via IRC Client pgardner.net:6667
room #PHP
Old January 17th, 2005, 12:49 PM
Authorized User
Join Date: Jan 2005
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts

Is there a reason that you have PHP installed as a CGI?

Old January 24th, 2005, 01:50 AM
Registered User
Join Date: Jan 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts

Found this on another forum if it helps.

Start the IIS management console (Start => Settings => Control Panel => Administrative Tools => Internet Services Manager).
In the tree on the left-hand side of the console you should see "Internet Information Services" at the very top, then below this the name of your computer. Right-click your computer name and select "Properties".
Under "Master Properties" is a listbox; ensure that "WWW Service" is showing, then click the "Edit" button.
Click on the "Home Directory" tab.
Click on the "Configuration" button in the Application Settings area.
Click on the "Process Options" tab.
In the CGI Configurations area there is a "CGI script timeout" value specified in seconds. The default value is 300 seconds (5 minutes).
Change this value to whatever you would like your timeout to be.
Work your way out by clicking the "Ok" button on each window until you get right back to the IIS management console.
Close the management console.
Restart IIS by opening a command prompt (Start => Programs => Accessories => Command Prompt) and type the command:

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with CGI Counter arunmohanmp Perl 0 April 9th, 2006 12:40 AM
help! on CGI Error heerajee Pro PHP 0 February 2nd, 2006 05:17 AM
HELP: Perl CGI + Java marina Perl 1 January 23rd, 2006 07:41 AM
PHP5 CGI or CLI? freddo Beginning PHP 2 August 15th, 2004 07:20 PM
How to fix "CGI timeout" baoshenyi Pro PHP 1 October 1st, 2003 12:46 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.