Core 4.4.6 - Deleting old log files ... All of them

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
timxjr1300
Posts: 5
Joined: Fri Jun 26, 2015 9:49 am

Core 4.4.6 - Deleting old log files ... All of them

Post by timxjr1300 »

I have nagios core 4.4.6 running all configured and fully functional at last.
After a few days messing around with check_this and check_that the log files looked a bit messy so I decided to clear them out.

Following instructions around the web I deleted:-
All the files in /nagios/var/archives
/nagios/nagios.log
/nagios/retention.dat
/nagios/objects.cache

All well and good, restart, go to the web interface and all the services are 'Pending' and slowly going green.
So you go to the 'Event Log'' and see the restart messages which is also good....but...

At the top of the page is a left arrow "Latest Archive" and when you click on that.. "Error: Could not open log file '/usr/local/nagios/var/archives/nagios-01-20-2021-00.log' for reading!"
Click again and you go back another day with the same error message for that date and so on.

I was hoping that in deleting all the log files to effectively start from scratch, the cgi gui would have detected that.

Is there a way of completely deleting references to non-existent log files in the gui?
Locked