Migration tool?

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Migration tool?

Post by rajasegar »

Does Nagios have any tools or scripts to migrate selected servers with its services and dependencies like contacts etc from one server to another?

Thanks
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Migration tool?

Post by lmiltchev »

Are you looking for *something different* than "backing up and restoring XI" as described in our the document below?
https://assets.nagios.com/downloads/nag ... ios-XI.pdf

Can you elaborate?
Be sure to check out our Knowledgebase for helpful articles and solutions!
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Re: Migration tool?

Post by rajasegar »

lmiltchev wrote:Are you looking for *something different* than "backing up and restoring XI" as described in our the document below?
https://assets.nagios.com/downloads/nag ... ios-XI.pdf

Can you elaborate?
I am trying to move about 300 hosts out of 1 instance to another in small batches.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Migration tool?

Post by lmiltchev »

If you knew you didn't have any config errors, you could simply place your configs in the "/usr/local/nagios/etc/import" directory, and run reconfigure_nagios.sh:

Code: Select all

cd /usr/local/nagiosxi/scripts
./reconfigure_nagios.sh
Note: This *may* fail if you hit some config errors. For example, it is possible that on the "new" server you haven't defined some of the objects used in the configs that you are importing, i.e hostgroups, contacts, contactgroups, etc.

A better way would be to create a directory under "/usr/local/nagios/etc"

Code: Select all

mkdir /usr/local/nagios/etc/cfgprep
copy the configs in it, and import them from the Nagios XI web UI (CCM->Tools->Import Config Files). This way you could verify configuration prior to applying it.

Run the " Config File Management" tool (called "Write Config Files" tool in XI versions older than 5.3.0) after importing each batch to make sure you don't have any config errors. If they are no errors, apply configuration. If you see errors, fix them in the CCM, rerun the tool, and apply configuration if no errors are present.
Be sure to check out our Knowledgebase for helpful articles and solutions!
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Re: Migration tool?

Post by rajasegar »

lmiltchev wrote:If you knew you didn't have any config errors, you could simply place your configs in the "/usr/local/nagios/etc/import" directory, and run reconfigure_nagios.sh:

Code: Select all

cd /usr/local/nagiosxi/scripts
./reconfigure_nagios.sh
Note: This *may* fail if you hit some config errors. For example, it is possible that on the "new" server you haven't defined some of the objects used in the configs that you are importing, i.e hostgroups, contacts, contactgroups, etc.

A better way would be to create a directory under "/usr/local/nagios/etc"

Code: Select all

mkdir /usr/local/nagios/etc/cfgprep
copy the configs in it, and import them from the Nagios XI web UI (CCM->Tools->Import Config Files). This way you could verify configuration prior to applying it.

Run the " Config File Management" tool (called "Write Config Files" tool in XI versions older than 5.3.0) after importing each batch to make sure you don't have any config errors. If they are no errors, apply configuration. If you see errors, fix them in the CCM, rerun the tool, and apply configuration if no errors are present.
I am aware of this method. Thanks anyway.
Please close this thread.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: Migration tool?

Post by dwhitfield »

Glad to hear you have a method. I am going to lock the thread. Please feel free to post again if you have you another issue. Thank you for using the Nagios forums!
Locked