Renaming host & historical data
-
- Posts: 140
- Joined: Thu Apr 18, 2013 8:25 am
- Location: libexec
Renaming host & historical data
Is it possible to rename a host or service without loosing the historical data ?
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Renaming host & historical data
Not in Nagios Core. In Nagios XI this is mostly possible using the rename utility, however even then the availability report will not be fully correct unless you were to replace all of the host/service entries in the nagios.log and all of the log files in the archive directory.
-
- Posts: 140
- Joined: Thu Apr 18, 2013 8:25 am
- Location: libexec
Re: Renaming host & historical data
So:
- I rename the host
- the same time I use sed to replace the old name with the new one (nagios.log & archive directory)
Any other info saved somewhere?
- I rename the host
- the same time I use sed to replace the old name with the new one (nagios.log & archive directory)
Any other info saved somewhere?
-
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: Renaming host & historical data
This is where Core gets all of it's historical data unless you're talking perfdata which is a whole other debacle. I've never done it, but I expect what you're trying to achieve would yield favorable results, maybe.amprantino wrote:So:
- I rename the host
- the same time I use sed to replace the old name with the new one (nagios.log & archive directory)