Reads various nagios-related configuration files. More...
Static Public Member Functions | |
static | get_nagios_base_path () |
Fetch nagios base path as configured in config file. | |
static | get_nagios_etc_path () |
Fetch nagios etc path as configured in config file. | |
static | get_pipe () |
Fetch nagios command pipe as configured by the nagios_pipe setting. | |
static | parse_config_file ($config_file) |
Reads a configuration file in the format variable=value and returns it in an array. | |
static | get_status_info ($file= 'status.log', $section= 'programstatus') |
Fetch status info from nagios log file. | |
static | extract_stat_key ($key=false, &$arr=false) |
Extract values from status.log array returned from get_status_info(). |
Reads various nagios-related configuration files.
static System_Model::get_nagios_base_path | ( | ) | [static] |
Fetch nagios base path as configured in config file.
static System_Model::get_nagios_etc_path | ( | ) | [static] |
Fetch nagios etc path as configured in config file.
static System_Model::get_pipe | ( | ) | [static] |
Fetch nagios command pipe as configured by the nagios_pipe setting.
If the pipe does not exist or is not writable, fetch pipe as configured by command_file in nagios.cfg.
static System_Model::parse_config_file | ( | $ | config_file | ) | [static] |
Reads a configuration file in the format variable=value and returns it in an array.
lines beginning with # are considered to be comments
$config_file | The configuration file to parse |