loadavg

package module
v0.0.0-...-6c9d7c1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 26, 2013 License: BSD-2-Clause Imports: 2 Imported by: 0

README

loadavg

simple package for gathering the loadavg from your system

Documentation

Index

Examples

Constants

View Source
const (
	ONE_MIN  = 0
	FIVE_MIN = iota
	FIFTEEN_MIN
)

Variables

This section is empty.

Functions

func LoadAvg

func LoadAvg() ([3]float64, error)

LoadAvg returns the traditional 1, 5, and 15 min load averages.

Example
loadavg, err := LoadAvg()
if err != nil {
	log.Fatal(err)
}
fmt.Printf("loadavg: %2.2f, %2.2f, %2.2f", loadavg[ONE_MIN], loadavg[FIVE_MIN], loadavg[FIFTEEN_MIN])
Output:

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL