Logging and monitoring server load

We decided it would be a good idea to be able to periodically log server load so we can identify potential problems So I wrote a little script that outputs the current server load along with a timestamp in CSV format which can easily be called via CRON and send the output to a log file which can then be imported into a spreadsheet.

getload.c

Just compile it and run it. The output should be something like:

"1251834476","0.21"

It turns out that Nagios logs server load anyway, but not quite as accurately as this.

This entry was posted in Linux and tagged , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *