With every host, but rarely with DH, the server performance seems to suffer. But does it really, is the situation unusual and how does this compare to reseller accounts at other hosting companies? I've seen nifty graphs of server load, which may explain why there is a problem at some other hosts, but not necessarily highlight when there is a problem that my clients may experience.
... So, I thought I'd create a standard dyanamic page on each of my servers and have a separate server (DH) request the page and measure the time - perhaps once per hour using a Cron job. Here is some initial code that I have experimented with using a Cron job with wgets http://DH_domain.com/aa_monitor/monitor.php:
========================
<?php
$time_start = microtime(true);
$fcontents = join ('', file('http://domain_at_other_hoste.com/aa_monitor/'));
$time_end = microtime(true);
$time = $time_end - $time_start;
$monitor_results = date("F j, Y, g:i a") . ", domain_at_other_host.com, $time seconds" . "\n";
$myFile = fopen("monitor.txt","a");
if (!($myFile))
{
print ("Error: ");
print("monitor.txt could not be created\n");
exit;
}
fputs($myFile, $monitor_results);
fclose($myFile);
?>
==========================
I think the above generates the dynamic page on the other server and measures the time to time to generate and pull the html to the DH server. Seems like I should also pull a small image, but not sure how to do that.
So far both servers tested have always provided the html in less than a second in time periods when I am not aware of a problem. Interesting that sometimes the elapsed time is negative....
Comments, Suggestions for best low impact server monitoring ??
__________________
Dave
davebean@ecentral.com
... So, I thought I'd create a standard dyanamic page on each of my servers and have a separate server (DH) request the page and measure the time - perhaps once per hour using a Cron job. Here is some initial code that I have experimented with using a Cron job with wgets http://DH_domain.com/aa_monitor/monitor.php:
========================
<?php
$time_start = microtime(true);
$fcontents = join ('', file('http://domain_at_other_hoste.com/aa_monitor/'));
$time_end = microtime(true);
$time = $time_end - $time_start;
$monitor_results = date("F j, Y, g:i a") . ", domain_at_other_host.com, $time seconds" . "\n";
$myFile = fopen("monitor.txt","a");
if (!($myFile))
{
print ("Error: ");
print("monitor.txt could not be created\n");
exit;
}
fputs($myFile, $monitor_results);
fclose($myFile);
?>
==========================
I think the above generates the dynamic page on the other server and measures the time to time to generate and pull the html to the DH server. Seems like I should also pull a small image, but not sure how to do that.
So far both servers tested have always provided the html in less than a second in time periods when I am not aware of a problem. Interesting that sometimes the elapsed time is negative....
Comments, Suggestions for best low impact server monitoring ??
__________________
Dave
davebean@ecentral.com
Comment