5 releases
0.2.4 | Jun 12, 2024 |
---|---|
0.2.3 | Oct 25, 2023 |
0.2.1 | Sep 7, 2023 |
0.2.0 | Nov 9, 2021 |
0.1.0 | Nov 9, 2021 |
#141 in Operating systems
7,583 downloads per month
32KB
773 lines
kstat-rs
Rust interfaces to illumos's libkstat
.
lib.rs
:
Rust library for interfacing with illumos kernel statistics, libkstat
.
The illumos kstat
system is a kernel module for exporting data about the system to user
processes. Users create a control handle to the system with Ctl::new
, which gives them
access to the statistics exported by their system.
Individual statistics are represented by the Kstat
type, which includes information about
the type of data, when it was created or last updated, and the actual data itself. The Ctl
handle maintains a linked list of Kstat
objects, which users may walk with the Ctl::iter
method.
Each kstat is identified by a module, an instance number, and a name. In addition, the data may
be of several different types, such as name/value pairs or interrupt statistics. These types
are captured by the Data
enum, which can be read and returned by using the Ctl::read
method.
Dependencies
~230–720KB
~17K SLoC