PHP include and require statements fails after a number of executions

0

I'm having a very strange issue, where PHP include and require statements fails after a number of executions.

The site is running on IIS 7/Windows 2008 R2 and the site's content is stored in a remote share on another Windows Server 2008 R2.

PHP is version 5.3. The same thing does not happen when using version 5.2.

A test page with a require statement would work fine and after a number of refreshes it would start failing with the following error (in this case a warning, if it where a require statement it would throw a fatal error).

Warning: require(./site-header.php): failed to open stream: No such file or directory in \mynas\myshare\mysite\index.php on line 17 Fatal error: require(): Failed opening required './wp-blog-header.php' (include_path='.;C:\php\includes') in \mynas\myshare\mysite\index.php

Recycling the application poool would clear the condition for a little while until it happens again.

It is worth noticing that the issue does not show at all if the include is absolute.

Would appreciate any hints in how to troubleshot this issue.

ademar

Posted 2011-05-19T18:12:32.447

Reputation: 109

Are you a sysadmin or are you programming on a shared host? – random – 2011-05-19T18:35:58.030

I'm the sysadmin – ademar – 2011-05-19T18:45:33.743

When you are getting the error is the nas available from explorer? There are a couple of possible things that would cause this, one is reaching/exceeding maximum number of supported connections to the nas, the other is the nas being temporarily unavailable for some other reason (network issue, disk issue whatever). – chunkyb2002 – 2011-05-19T21:30:02.033

I've considered those probables but note that a different PHP version does not exhibit the issue, there is also ASP/ASP.NET apps running in the same server without any issues. I'm also aware of MaxCmds,MaxWorkItems and MaxMpxCT params. – ademar – 2011-05-20T04:31:32.647

I'm suspecting of FastCGI and some SMB 2.x quirk – ademar – 2011-05-20T04:41:19.470

The problem was due to Traverse/Execute permissions missing from the site's folder. I've detailed a little bit more over here

– ademar – 2012-08-28T13:57:44.317

No answers