Page 1 of 1

Nagios XI backup failed

Posted: Wed Sep 18, 2019 4:02 am
by CatherineCusack
Hi all,

I've recently took over Nagios XI from another person and have ran into a problem; when I try to back it up on the web interface nothing happens so I decided to run the backup command

Code: Select all

# /usr/local/nagiosxi/scripts/backup_xi.sh
However when I run it I keep getting the same message:

Code: Select all

 Backing up MySQL databases...
mysqldump: Got error: 144: "Table './nagios/nagios_conninfo' is marked as crashed and last (automatic?) repair failed" when using LOCK TABLES
Error backing up MySQL database 'nagios' - check the password in this script! 
And I know that I need to repair the database but I've read some articles and they all say to back it up beforehand, so basically I'm just wondering if I can repair the database and then run the backup?

Note: the last backup was around 2 weeks ago and since that I have had to fix a few minor things that can be easily done again if need be.

Any help is much appreciated!

Re: Nagios XI backup failed

Posted: Wed Sep 18, 2019 6:23 am
by scottwilkerson
You cannot run a backup of Nagios XI with a broken database. If you have a VM environment you probably can create a snapshot.

https://assets.nagios.com/downloads/nag ... tabase.pdf

Re: Nagios XI backup failed

Posted: Wed Sep 18, 2019 8:37 am
by CatherineCusack
Thanks for replying, I did that and then ran the script to repair the database which worked and the ran the backup script and it also worked, so all is going again.

Thanks a lot!

Re: Nagios XI backup failed

Posted: Wed Sep 18, 2019 9:39 am
by scottwilkerson
CatherineCusack wrote:Thanks for replying, I did that and then ran the script to repair the database which worked and the ran the backup script and it also worked, so all is going again.

Thanks a lot!
Great!

Locking