#linux #cpu #metrics #load #memory #statistics

nightly os_stat

A library to get system metrics like cpu load and memory usage

1 unstable release

0.1.0 Sep 30, 2020

#728 in Operating systems

21 downloads per month

Apache-2.0

22KB
549 lines

OS system statistics library for Rust

This is a library to get system metrics like cpu load and memory usage, inspired by go-osstat.

Cargo.toml

os_stat = "0.1"

Example

extern crate os_stat;

fn main() {
    dbg!(os_stat::CPU::get());
}

Supported OS

Only Linux(>= 2.6.33)

TODOs

  • Better error-handling
  • Support macOS
  • Support Windows

Dependencies

~42KB