Page 2 of 2

Re: Nagios disk full and conf changes doesnt apply

Posted: Tue Mar 11, 2014 5:27 am
by Loul42
Also if i dont want to backup my nagios
What is the best way to stop performance data ? and to change the directory where files are saved ?
Part of my nagios.cfg :

# PNP settings - bulk mode with NCPD
process_performance_data=1
# service performance data
service_perfdata_file=/usr/local/nagios/var/service-perfdata
service_perfdata_file_template=DATATYPE::SERVICEPERFDATA\tTIMET::$TIMET$\tHOSTNAME::$HOSTNAME$\tSERVICEDESC::$SERVICEDESC$\tSERVICEPERFDATA::$SERVICEPERFDATA$\tSERVICECHECKCOMMAND::$SERVICECHECKCOMMAND$\tHOSTSTATE::$HOSTSTATE$\tHOSTSTATETYPE::$HOSTSTATETYPE$\tSERVICESTATE::$SERVICESTATE$\tSERVICESTATETYPE::$SERVICESTATETYPE$
service_perfdata_file_mode=a
service_perfdata_file_processing_interval=15
service_perfdata_file_processing_command=process-service-perfdata-file-pnp-bulk
# host performance data
host_perfdata_file=/usr/local/nagios/var/host-perfdata
host_perfdata_file_template=DATATYPE::HOSTPERFDATA\tTIMET::$TIMET$\tHOSTNAME::$HOSTNAME$\tHOSTPERFDATA::$HOSTPERFDATA$\tHOSTCHECKCOMMAND::$HOSTCHECKCOMMAND$\tHOSTSTATE::$HOSTSTATE$\tHOSTSTATETYPE::$HOSTSTATETYPE$
host_perfdata_file_mode=a
host_perfdata_file_processing_interval=15
host_perfdata_file_processing_command=process-host-perfdata-file-pnp-bulk

-------
If I change like this :

process_performance_data=0
# service performance data
service_perfdata_file=/data/perfdata

and restart nagios engine, will it work ?

Thanks

Re: Nagios disk full and conf changes doesnt apply

Posted: Tue Mar 11, 2014 10:54 am
by slansing
Well, that will certainly stop Nagios from processing the incoming performance data, this will be for all objects you are monitoring, is this what you are looking to do?

Re: Nagios disk full and conf changes doesnt apply

Posted: Thu Mar 13, 2014 3:28 am
by Loul42
Hello

I dont think we are using performance data so yes this is what i am looking to do.

Can I do a backup today everything (with the script) except mysql and postgresql . And then add mysql and postgres from January backup to the zip and then restore this zip.
Will it work ? (As I want my system be backupped as it was in January, but I only have mysql and postgre backupped)

Re: Nagios disk full and conf changes doesnt apply

Posted: Thu Mar 13, 2014 10:52 am
by abrist
Potentially. If you were using static configs, or custom plugins, you will have to resolve those issues after the restore before apply configuration and specific checks will work.
I suggest keeping the old install available through the process just in case you need to recover something from the old install.