Right now I don’t have time to optimize and to upgrade servers and once or twice a month the server reaches critical load (mysql basically) and it goes very very slow.
I want to show a static message saying the server is too busy when that happens.
How would I do that?
There’s a function for that: http://www.php.net/manual/en/function.sys-getloadavg.php
example usage: