Linux commands: Difference between revisions
Jump to navigation
Jump to search
m
→Using PHP function
| Line 310: | Line 310: | ||
* CPU usage = LoadPercentage; unit: % | * CPU usage = LoadPercentage; unit: % | ||
==== Using PHP function ==== | ==== Using PHP function to obtain system load average ==== | ||
on freebsd, {{Linux}} & {{Mac}}: | on freebsd, {{Linux}} & {{Mac}}: | ||
* PHP function [http://php.net/manual/en/function.sys-getloadavg.php sys_getloadavg()] unit: %; '''Need''' to divide by CPU cores number | * PHP function [http://php.net/manual/en/function.sys-getloadavg.php sys_getloadavg()] unit: %; '''Need''' to divide by CPU cores number | ||
=== System CPU usage === | === System CPU usage === | ||