Upgrading Nagios cluster from 5.7 to 5.11 failed

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Post Reply
arista-nagios
Posts: 11
Joined: Fri Sep 21, 2018 12:58 am

Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by arista-nagios »

I have a Nagios cluster of two nodes configured with pacemaker corosync and drbd.

Nagios version: 5.7
upgrading to: 5.11.3
Reference article: https://assets.nagios.com/downloads/nag ... ctions.pdf

Error:
-----------

*** Configuration summary for ***:

----------------
User: nagios
Group: nagios
Bin directory: /usr/local/nagios/bin
Config directory: /usr/local/nagios/etc
Nagios config: /usr/local/nagios/etc/nagios.cfg
----------------

Review the options above for accuracy. If they look okay,
type 'make all' to compile NDOUtils, or type 'make' to get
a list of make options.

cd src/ && make ndo.so
make[1]: Entering directory `/tmp/nagiosxi/subcomponents/ndo/ndo-3.1.0/src'
gcc -fPIC -shared -g -O2 -I/usr/include/mysql ndo.c -o ndo.so -L/usr/lib64/mysql -lmysqlclient -lpthread -lz -lm -ldl -lssl -lcrypto -pthread
ndo.c:155:12: warning: ‘database_instance_id’ initialized and declared ‘extern’ [enabled by default]
extern int database_instance_id = 1;
^
make[1]: Leaving directory `/tmp/nagiosxi/subcomponents/ndo/ndo-3.1.0/src'
cd src/ && make ndo.so
make[1]: Entering directory `/tmp/nagiosxi/subcomponents/ndo/ndo-3.1.0/src'
make[1]: `ndo.so' is up to date.
make[1]: Leaving directory `/tmp/nagiosxi/subcomponents/ndo/ndo-3.1.0/src'
/usr/bin/install -c -m 774 -o nagios -g nagios src/ndo.so /usr/local/nagios/bin/ndo.so
Shared module ndo.so installed
/usr/local/nagios/etc/nagios.cfg configured to use NDO
UPGRADE: POST-UPGRADE: NDO post upgrade started...
Performing upgrade...
> Upgrading from version 3.0.4 (/tmp/nagiosxi/subcomponents/ndo/ndo-3.1.0/db/upgrade-from-3.0.4.sql)
ERROR 144 (HY000) at line 7: Table './nagios/nagios_logentries' is marked as crashed and last (automatic?) repair failed
Automated migration failed on file upgrade-from-3.0.4.sql!
The 'nagios' database is not in a usable configuration.
Please revert to your pre-upgrade snapshot and reach out to the Support Team.
jsimon
Posts: 339
Joined: Wed Aug 23, 2023 11:27 am

Re: Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by jsimon »

Hi @arista-nagios,

I would recommend running the following command to repair your database:

Code: Select all

cd /usr/local/nagiosxi/scripts/
./repair_databases.sh
If you run into errors running this, please follow up and let us know what Linux distro your server is installed on, as there are some more steps to take if the repair_databases.sh script isn't successful, but they are distro-dependant.
arista-nagios
Posts: 11
Joined: Fri Sep 21, 2018 12:58 am

Re: Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by arista-nagios »

I possess a Nagios XI license and need to arrange a meeting to address challenges encountered during the Nagios cluster upgrade. This is urgent for us. I noticed a 'community support forum for Nagios commercial products' at the top of the page. Is this the enterprise support portal, or could you redirect me to the correct Nagios XI enterprise support portal?
User avatar
jmichaelson
Posts: 375
Joined: Wed Aug 23, 2023 1:02 pm

Re: Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by jmichaelson »

This is not the enterprise support portal. Enterprise support information can be found her: https://www.nagios.com/support-plans/
Please let us know if you have any other questions or concerns.

-Jason
arista-nagios
Posts: 11
Joined: Fri Sep 21, 2018 12:58 am

Re: Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by arista-nagios »

Yes, is there any guide or document to upgrade a nagios-cluster?
Repairing the db fixed my nagios but I still need to update it to the latest version.
jsimon
Posts: 339
Joined: Wed Aug 23, 2023 11:27 am

Re: Upgrading Nagios cluster from 5.7 to 5.11 failed

Post by jsimon »

Yes, you can follow this guide to update your Nagios XI to the latest version:

https://assets.nagios.com/downloads/nag ... ctions.pdf
Post Reply