Intermittent 404

Permalink
We have recently moved a site onto a new host and now are occasionally (2 or 3 times a day) getting a 404 error when accessing the site (admin or user).

Tech support are saying that this is the only php site they have running that is causing problems, and that it is definitely down to routing however I would have thought that a routing issue would happen every time. The .htaccess file contains the following
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]


and the default page on the site is index.php
# concrete5 Version
Core Version - 8.3.2
Version Installed - 8.3.2
Database Version - 20180122213656

# concrete5 Cache Settings
Block Cache - Off
Overrides Cache - Off
Full Page Caching - Off
Full Page Cache Lifetime - Every 6 hours (default setting).

# Server Software
Microsoft-IIS/10.0

# Server API
cgi-fcgi

# PHP Version
7.2.7

recycling the app pool solves the problem because that is basically restarting everything, but even doing that every 2 hours doesn't solve this problem (and you shouldn't need to do it that often anyway).

Any sensible ideas (another host is not sensible) would be greatly received as I am at a loss as to where to go next

View Replies:
JohntheFish replied on at Permalink Reply
JohntheFish
The usual suspects for such issues after moving a site is URLs for pages and images that have been directly entered into rich text or html, rather than using the c5 page and file pickers.

Also check tracking codes and any custom code such as theme and block templates for similar mistakes.

Other possible culprits are cache and database entities. Clear the cache and refresh entities.
pjd replied on at Permalink Reply
Thanks, I will look at this, however surely if it was urls being hard coded this would happen every time the page loaded.

I am currently checking every 15 minutes, so it loads at least 4 times every hour and only fails a few times a day
JohntheFish replied on at Permalink Reply
JohntheFish
Your suspicions may be valid. This could be more than a matter of coded URLs or the usual cache/entity issues.

You will need to collect more evidence. Things like a dev console network tab trace leading up to the 404, whether it contains any redirects, alternate URL slugs, things like that.

Are there any proxies involved? If so, are all the proxy IP addresses listed in the dashboard? Even though the c5 cache is off, a proxy could also be caching.
pjd replied on at Permalink Reply
Looking at the server logs I have managed to track narrow it down a bit.
sometimes it seems to be trying to access
mysite.com/index.php/mypage/index.php - which will return a 404
after which it would not return any pages even when the address was correct
(although manually calling that address does not cause it to fail).

I'm still grasping at straws, but am wondering if the rewriter is competing with the default page?