New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

system-stats

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

system-stats

Access host's file system, processor and memory usage.

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-85.71%
Maintainers
1
Weekly downloads
 
Created
Source

system-stats

Access host's file system, processor and memory usage.

This NPM package is written in ES6, so it is recommended to use strictly Node >= v6.4.0.

Usage

This package returns a Promise:

const system_stats = require('./system-stats.js')

//  (1) Ask for system stats
system_stats.get()
//  (2) Process promise response
.then( ( results ) => {
  console.dir( results )
}, ( error ) => {
  console.error( error )
} )

Output

Parameters and Units

{
  // [1, 5, 15]-minute CPU avgs normalized to [0.0, 1.0]:
  proc: [ 0.005576171875, 0.008974609375, 0.010400390625 ],
  mem: {
    total: 16737234944,         //  bytes
    free: 4571918336,           //  bytes
    load: 0.7268414794141997    //  normalized to [0.0, 1.0]
  },
  uptime: 747954,               //  seconds
  fs: {
    available: 2335936512,      //  bytes
    free: 5330980864,           //  bytes
    total: 58495991808,         //  bytes
    load: 0.9600667252609856    //  normalized to [0.0, 1.0]
  }
}

Keywords

FAQs

Package last updated on 07 Mar 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc