Page 1 of 1

Restore DB from 5.7.5 to 5.8.5

Posted: Tue Aug 17, 2021 4:56 am
by rajasegar
Hi,

Can you advice if there will be any issues to restore DB backup from Nagios XI 5.7.5 to 5.8.5?
Source DB is from XI Ent 5.7.5 RHEL6.x and target is Nagios XI Ent 5.8.5 RHEL 7.9.

Thanks

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Tue Aug 17, 2021 11:13 am
by ssax
It is not recommended to restore DBs or XI backups to different versions of XI, you will likely cause issues.

The recommendation would be for you to install XI 5.7.5 on a RHEL 7.9 server and then use the backup/restore process to migrate to it, then upgrade the new system to XI 5.8.5:

Is your current system running 32-bit or 64-bit?

Code: Select all

uname -a
The XI backup/restore process makes this pretty easy:

The process is this:
- Spin up new server running EL7/EL8 latest

- Install the exact same version of XI that the old server has on the new server, no need to configure it, just install it and go through the initial setup (do not try to restore over different versions of XI you will cause issues)

https://assets.nagios.com/downloads/nag ... -Linux.pdf

- If you have a RAMDisk installed, are using RRDCacheD, or are running Mod_Gearman on the old system, set them up before restoring:

https://assets.nagios.com/downloads/nag ... giosXI.pdf
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
https://assets.nagios.com/downloads/nag ... ios_XI.pdf

If you are monitoring vmware/oracle you'll need to reinstall the proper supporting packages on the new server again following these guides:

https://assets.nagios.com/downloads/nag ... ios-XI.pdf
https://assets.nagios.com/downloads/nag ... ios-XI.pdf

- Backup the old/transfer to new/restore to the new

- Follow the After The Restore section from the backup/restore guide completely

- Since you're changing OS versions, run the restore_repair script from the backup/restore guide

https://assets.nagios.com/downloads/nag ... ios-XI.pdf

- Shutdown (or re-IP) the old, set the old IP on the new system so you don't have to update agent configs/FW rules

https://support.nagios.com/kb/article/c ... s-549.html

That's pretty much it. Please be aware of what a single XI license entitles you to:

https://support.nagios.com/kb/article.php?id=145

Then apply configuration and upgrade the new server to the latest XI version.

If your current system is 32-bit you need to follow this as well to migrate the performances, if it's 64-bit already, no need to follow this:

https://support.nagios.com/kb/article.php?id=166

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Wed Aug 18, 2021 5:32 am
by rajasegar
Mine is 64bit. Thanks for the input

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Wed Aug 18, 2021 10:30 am
by rajasegar
How do you downgrade from 5.8.5 to 5.7.5? Is it possible?
Or uninstall the existing XI instance.

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Wed Aug 18, 2021 11:59 am
by pbroste
Hello @rajasegar

It is recommended to uninstall the 5.8.5 and go ahead and install the 5.8.5.

Here's is a uninstall script that a team member wrote to clean things up.

*** BEFORE YOU DO THIS, READ IT LINE BY LINE AND UNDERSTAND WHAT IT DOES (and it's impact on anything existing you have on the system, the script assumes it's ONLY an XI system) BY REVIEWING THE SCRIPT THOROUGHLY (IT REMOVES EVERYTHING, INCLUDING THE HISTORICAL DATA), IF YOU DO NOT WANT THAT, DON'T PROCEED FURTHER!

*** USE AT YOUR OWN RISK, THIS WILL CAUSE DATA LOSS (ALL MYSQL and PSQL DB data will be removed) AND IMPACT THE PACKAGES WE USE (that you may also use if this is a dual purpose server (it shouldn't be)!

Here is the download link for archives:

https://assets.nagios.com/downloads/nagiosxi/versions.php

Let us know if you have any questions or if I can clarify anything.

Thanks,
Perry

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Thu Aug 19, 2021 3:41 am
by rajasegar
Can I know where is all the custom dashboards stored in Nagios XI?
I need to transfer some of them to the new instance.
What is the best way to go about this?

Re: Restore DB from 5.7.5 to 5.8.5

Posted: Thu Aug 19, 2021 2:32 pm
by pbroste
Hello @rajasegar


Unfortunately, the dashboard information is stored in the database and XI currently does not have the option to import/export specific dashboards as they are categorized with serial#'s. You can view the information in the database by running the following query.

Code: Select all

echo "select * from xi_usermeta where keyname = 'dashboards';" | mysql -uroot -pnagiosxi nagiosxi
Thanks,
Perry