NameSilo

[Resolved] Strange file() issue - PHP

Spaceship Spaceship
Watch

ScottAN

Established Member
Impact
1
Strange file() issue - PHP

So I am trying to resolve an issue with my companies server status script that we use to monitor a number of servers. It checks using cron and gets the load averages for each server by using the file() command to access a server side php file that reports the load avg. ANYWAY.. I'm getting this error when accessing ONLY ONE of the servers:

Code:
PHP Warning:  file(http://IPADDRESS:80/server_script.php): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found

Out of ~30 servers only one is causing this error. I've checked the firewall on the server causing the error and thats not the issue. I've flushed DNS on the checking server and the server causing the error. Even stranger, using

Code:
wget http://IPADDRESS:80/server_script.php

through the shell works just fine. Has anyone experienced anything like this??
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
More info please

What kind of host is it? Windows, Linux??

Have you tried launching the script as a local admin using http://localhost/server_script.php on problem machine to rule out IP or router issues? Are you certain that the host is listening on port 80?

Just some basic troubleshooting steps. Maybe you've already tried them but it is always easy to overlook something.
 
0
•••
Issue is resolved now thanks for the suggestions. It turned out to be a misconfiguration with httpd.conf (a mod_security issue).
 
0
•••
Appraise.net

We're social

Unstoppable Domains
Domain Recover
NameMaxi - Your Domain Has Buyers
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back