Page 1 of 1

Data retaintion duration

Posted: Fri Nov 03, 2017 3:48 pm
by lrnnetops
Hi Team,

We are using nagios XI ver. 5.4.8

Please help with below points.

1 - Duration of RAW data retained by nagios xi. if its gets purge help us with how & where it gets purge.

2 - Duration of logs retention period.

3 - Alerts data retention period.

Thanks,
Rohan

Re: Data retaintion duration

Posted: Mon Nov 06, 2017 12:41 pm
by lrnnetops
Hi Team,

Need your help on this.

Regards,
Rohan

Re: Data retaintion duration

Posted: Mon Nov 06, 2017 12:50 pm
by npolovenko
Hello, @lrnnetops.

1. Nagios XI stores RAW performance data in Round Robin Database. It automatically shrinks and averages out the older performance data, optimizing the storage consumption. There is no available/reliable GUI option to change the historical data retention period as of right now, however, if you take a look at this file:

Code: Select all

nano /usr/local/nagios/etc/pnp/rra.cfg
You will see:

Code: Select all

RRA:AVERAGE:0.5:30:4320
#
# 5840 entries with 360 minute step = 4 years
#
RRA:AVERAGE:0.5:360:5840
So Nagios will store performance data for 4 years. But again, it should not consume huge amounts of storage because of the optimization process.

If you'd like to delete RRD files you can check this direcotry:

Code: Select all

/usr/local/nagios/share/perfdata
2. You could check and modify log retention times in /usr/local/nagiosxi/html/config.inc.php You could also run ls -l command in key nagios log directories and delete logs older than X date. Here's the link to learn more about log locations https://assets.nagios.com/downloads/nag ... gIGjfD_BwE

3. Alerts would be stored in nagios.log file. By default, each day Nagios archives that file and puts the old ones in

Code: Select all

/usr/local/nagios/var/archives
You could modify that setting in /usr/local/nagios/etc/nagios.cfg:

Code: Select all

log_rotation_method=d
# n = None - don't rotate the log
# h = Hourly rotation (top of the hour)
# d = Daily rotation (midnight every day)
# w = Weekly rotation (midnight on Saturday evening)
# m = Monthly rotation (midnight last day of month)

Did that answer your questions?