Home  >  Article  >  Backend Development  >  Solve the problem of Nagios/Icinga -pnp4 not displaying graphics

Solve the problem of Nagios/Icinga -pnp4 not displaying graphics

巴扎黑
巴扎黑Original
2016-11-11 11:43:291303browse

Recently I am using icinga to deploy and monitor. After using icinga-pnp4 to deploy, the graphics showing historical data cannot be displayed, and an error message is reported:

The localhost directory does not exist, or the localhost directory is empty

After research, it was finally confirmed that it is Because the perfdata option is not turned on in the icinga configuration file icinga.cfg, icinga will not store historical data in the specified directory. You only need to open them all and restart the icinga service to display historical data graphics.

For the perfdata configuration items, remove the # in front, as follows:

958:process_performance_data=1

972:host_perfdata_command=pnp4-process-host-perfdata

973:service_perfdata_command=pnp4-process -service- perfdata

982:host_perfdata_file=/tmp/host-perfdata

983:service_perfdata_file=/tmp/service-perfdata

995:host_perfdata_file_template=[HOSTPERFDATA]t$TIMET$t$HOSTNAME $t$HOSTEXECUTIONTIME$ t$HOSTOUTPUT$t$HOSTPERFDATA$

996:service_perfdata_file_template=[SERVICEPERFDATA]t$TIMET$t$HOSTNAME$t$SERVICEDESC$t$SERVICEEXECUTIONTIME$t$SERVICELATENCY$t$SERVICEOUTPUT$t$SERVICEPERFDATA$

1007 :host_perfdata_file_mode=a

1008:service_perfdata_file_mode=a

1018:host_perfdata_file_processing_interval=0

1019:service_perfdata_file_processing_interval=0

1 028:host_perfdata_file_processing_command=process-host-perfdata-file

1029:service_perfdata_file_processing_command=process- service-perfdata-file

1040:host_perfdata_process_empty_results=1

1041:service_perfdata_process_empty_results=1


Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn