an operating-system utility library. Some methods are wrappers of Node libraries and others are calculation made by the module.
One line instaltion with npm.
npm install os-utils
Then in your code
var os = require('os-utils');
os.cpuUsage(function(v){
console.log( 'CPU Usage (%): ' + v );
});
os.cpuFree(function(v){
The follwoing methods are available:
Calculate CPU usage in the next second. This is not an average of CPU usage like in the "os" module. The callback will receive a parameter with the value
os.cpuUsage( callback );
Calculate free CPU in the next second. This is not based on average CPU usage like in the "os" module. The callback will receive a parameter with the value
os.cpuFree( callback );
os.platform();
os.countCPUs()
os.freemem()
os.totalmem()
os.freememPercentage()
os.sysUptime();
os.processUptime()
os.loadavg(1)
os.loadavg(5)
os.loadavg(15)