0

I'm creating a php script that will capture certain information from the server and database at regular intervals. The server is running LAMP.

Is there a way to output the server load, or other statistics that may indicate the performance or load on the server including mysql?

Jon Lin
  • 135,941
  • 26
  • 200
  • 209
Lyon
  • 7,144
  • 10
  • 29
  • 45

1 Answers1

0

Just try

cat /proc/loadavg

or

uptime

which printout the current load of the servers 1 min / 10 min / 15 min interval.

May be you should take a look to http://munin-monitoring.org/ or may be nagios

khmarbaise
  • 81,692
  • 23
  • 160
  • 199
  • thank you! with your help i managed to find php function sys_getloadavg(). Do you know how I may determine the mysql database load? say...available connections vs max connection limit? thanks :) – Lyon Aug 06 '10 at 01:25