NAME

Sys::Statistics::Linux::CpuInfo - Collect linux cpu statistics.

SYNOPSIS

use Sys::Statistics::Linux::CpuInfo;

my $lxs  = new Sys::Statistics::Linux::CpuInfo;
my $info = $lxs->get;

DESCRIPTION

Sys::Statistics::Linux::CpuInfo gathers cpu informations from the virtual /proc filesystem (procfs).

For more informations read the documentation of the front-end module Sys::Statistics::Linux.

CPU STATISTICS

Generated by /proc/cpuinfo for each cpu (cpu0, cpu1 ...).

model_name  - The model name.
cpu_mhz     - The speed in MHz of the processor.
cache_size  - The cache size of the prozessor.
bogomips    - The speed in bogomips of the processor.

Note that not all keys are available on different hardware architectures. If you meet a arch that provide a different place to find the keys then I would be pleased if you send me an output of /proc/cpuinfo.

METHODS

new()

Call new() to create a new object.

my $lxs = Sys::Statistics::Linux::CpuInfo->new;

get()

Call get() to get the statistics. get() returns the statistics as a hash reference.

my $info = $lxs->get;

EXPORTS

No exports.

SEE ALSO

proc(5)

REPORTING BUGS

Please report all bugs to <jschulz.cpan(at)bloonix.de>.

AUTHOR

Jonny Schulz <jschulz.cpan(at)bloonix.de>.

COPYRIGHT

Copyright (c) 2006, 2007 by Jonny Schulz. All rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.