Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var TimeoutDuration = 30 * time.Second
TimeoutDuration is option of `Runcommand()` set timeout limit of command execution.
View Source
var TimeoutKillAfter = 10 * time.Second
TimeoutKillAfter is option of `RunCommand()` set waiting limit to `kill -kill` after terminating the command.
Functions ¶
func RunCommand ¶
RunCommand runs command (in two string) and returns stdout, stderr strings and its exit code.
func RunCommandArgs ¶ added in v0.38.0
RunCommandArgs run the command
func SanitizeMetricKey ¶ added in v0.36.0
SanitizeMetricKey sanitize metric keys to be Mackerel friendly
Types ¶
type DfStat ¶ added in v0.34.0
type DfStat struct { Name string Blocks uint64 Used uint64 Available uint64 Capacity uint8 Mounted string }
DfStat is disk free statistics from df command. Field names are taken from column names of `df -P`
func CollectDfValues ¶ added in v0.16.1
CollectDfValues collects disk free statistics from df command
Click to show internal directories.
Click to hide internal directories.