updating from nagios XI 2014R2.6 to 2014R2.7
updating from nagios XI 2014R2.6 to 2014R2.7
Hello,
We are trying to update our nagios XI 2014R2.6 to 2014R2.7. As listed in the Backing-Up-And-Restoring-Nagios-XI document we tried to backup, however, the backup failed with the following error.
i# /usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
I'm not sure if we changed the password of nagios db. Can assistance be provided ?
We are trying to update our nagios XI 2014R2.6 to 2014R2.7. As listed in the Backing-Up-And-Restoring-Nagios-XI document we tried to backup, however, the backup failed with the following error.
i# /usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
I'm not sure if we changed the password of nagios db. Can assistance be provided ?
Re: updating from nagios XI 2014R2.6 to 2014R2.7
First try running through the steps in this doc, and post any errors that may come about...
https://assets.nagios.com/downloads/nag ... tabase.pdf
https://assets.nagios.com/downloads/nag ... tabase.pdf
Be sure to check out the Knowledgebase for helpful articles and solutions!
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Thank you. I will try and report back.
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Sounds good, we'll be watching for any updates -
Be sure to check out the Knowledgebase for helpful articles and solutions!
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Hello,
As advised, i fixed the mysql with the script in the document provided. Output attached. It seems that the repairmysql script had fixed the mysql db. However, i get the same error when i run the backupscript after fixing the mysql db.
usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
Any suggestions ?
As advised, i fixed the mysql with the script in the document provided. Output attached. It seems that the repairmysql script had fixed the mysql db. However, i get the same error when i run the backupscript after fixing the mysql db.
usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
Any suggestions ?
You do not have the required permissions to view the files attached to this post.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Page 2 of the document, has additional steps if you are still seeing "is marked as crashed" errors
https://assets.nagios.com/downloads/nag ... tabase.pdf
https://assets.nagios.com/downloads/nag ... tabase.pdf
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Thank you.
myisamchk -r -f nagios_logentries
- recovering (with sort) MyISAM-table 'nagios_logentries'
Data records: 961
- Fixing index 1
- Fixing index 2
- Fixing index 3
- Fixing index 4
/usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
same error. Am i missing something ?
myisamchk -r -f nagios_logentries
- recovering (with sort) MyISAM-table 'nagios_logentries'
Data records: 961
- Fixing index 1
- Fixing index 2
- Fixing index 3
- Fixing index 4
/usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
same error. Am i missing something ?
Re: updating from nagios XI 2014R2.6 to 2014R2.7
If running "myisamchk -r -f nagios_logentries" didn't fix the issue, you could try:
Code: Select all
echo 'repair table nagios_logentries use_frm;' | mysql -t -u root -pnagiosxi nagiosBe sure to check out our Knowledgebase for helpful articles and solutions!
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Well, it's same even after running the command.
Code: Select all
# echo 'repair table nagios_logentries use_frm;' | mysql -t -u root -pnagiosxi nagios
+--------------------------+--------+----------+--------------------------------------+
| Table | Op | Msg_type | Msg_text |
+--------------------------+--------+----------+--------------------------------------+
| nagios.nagios_logentries | repair | warning | Number of rows changed from 0 to 961 |
| nagios.nagios_logentries | repair | status | OK |
+--------------------------+--------+----------+--------------------------------------+
# /usr/local/nagiosxi/scripts/backup_xi.sh
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 144: Table './nagios/nagios_logentries' 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!
Last edited by tmcdonald on Tue May 31, 2016 5:06 pm, edited 1 time in total.
Reason: Please use [code][/code] tags around long output
Reason: Please use [code][/code] tags around long output
Re: updating from nagios XI 2014R2.6 to 2014R2.7
Let's try running this command again:
Next, restart mysql and show the last 50 lines of the mysqld.log.
Is opening a new support ticket in our email ticketing system an option for you?
Code: Select all
echo 'repair table nagios_logentries use_frm;' | mysql -t -u root -pnagiosxi nagiosCode: Select all
service mysqld restart
tail -50 /var/log/mysqld.logBe sure to check out our Knowledgebase for helpful articles and solutions!