pub struct HostCpu {Show 17 fields
pub load_one: u32,
pub load_five: u32,
pub load_fifteen: u32,
pub proc_run: u32,
pub proc_total: u32,
pub cpu_num: u32,
pub cpu_speed: u32,
pub uptime: u32,
pub cpu_user: u32,
pub cpu_nice: u32,
pub cpu_system: u32,
pub cpu_idle: u32,
pub cpu_wio: u32,
pub cpu_intr: u32,
pub cpu_sintr: u32,
pub interrupts: u32,
pub contexts: u32,
}Expand description
Host CPU - Format (0,2003)
Physical server CPU statistics
§XDR Definition (sFlow Host)
/* Physical Server CPU */
/* opaque = counter_data; enterprise = 0; format = 2003 */
struct host_cpu {
float load_one; /* 1 minute load avg */
float load_five; /* 5 minute load avg */
float load_fifteen; /* 15 minute load avg */
unsigned int proc_run; /* running processes */
unsigned int proc_total; /* total processes */
unsigned int cpu_num; /* number of CPUs */
unsigned int cpu_speed; /* CPU speed in MHz */
unsigned int uptime; /* seconds since last reboot */
unsigned int cpu_user; /* user time (ms) */
unsigned int cpu_nice; /* nice time (ms) */
unsigned int cpu_system; /* system time (ms) */
unsigned int cpu_idle; /* idle time (ms) */
unsigned int cpu_wio; /* I/O wait time (ms) */
unsigned int cpu_intr; /* interrupt time (ms) */
unsigned int cpu_sintr; /* soft interrupt time (ms) */
unsigned int interrupts; /* interrupt count */
unsigned int contexts; /* context switch count */
}Fields§
§load_one: u32Load average (1 minute) - stored as hundredths (multiply by 100)
load_five: u32Load average (5 minutes) - stored as hundredths (multiply by 100)
load_fifteen: u32Load average (15 minutes) - stored as hundredths (multiply by 100)
proc_run: u32Number of running processes
proc_total: u32Total number of processes
cpu_num: u32Number of CPUs
cpu_speed: u32CPU speed in MHz
uptime: u32CPU uptime in seconds
cpu_user: u32CPU time in user mode (ms)
cpu_nice: u32CPU time in nice mode (ms)
cpu_system: u32CPU time in system mode (ms)
cpu_idle: u32CPU idle time (ms)
cpu_wio: u32CPU time waiting for I/O (ms)
cpu_intr: u32CPU time servicing interrupts (ms)
cpu_sintr: u32CPU time servicing soft interrupts (ms)
interrupts: u32Number of interrupts
contexts: u32Number of context switches
Trait Implementations§
impl Eq for HostCpu
impl StructuralPartialEq for HostCpu
Auto Trait Implementations§
impl Freeze for HostCpu
impl RefUnwindSafe for HostCpu
impl Send for HostCpu
impl Sync for HostCpu
impl Unpin for HostCpu
impl UnwindSafe for HostCpu
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more