Hello,
I have the following ERROR in mariadb.log file :
200124 9:39:57 [ERROR] mysqld: Table './nagios/nagios_logentries' is marked as crashed and last (automatic?) repair failed
and a huge number of these warnings thrown in the log continuously:
200124 9:39:52 [Warning] Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. INSERT... ON DUPLICATE KEY UPDATE on a table with more than one UNIQUE KEY is unsafe Statement: INSERT INTO nagios_servicestatus....
and logentries table is NULL:
[root@olexpnagiosp01 ~]# echo "SELECT table_name AS 'Table', round(((data_length + index_length) / 1024 / 1024), 2) 'Size in MB' FROM information_schema.TABLES WHERE table_schema IN ('nagios', 'nagiosql', 'nagiosxi');" | mysql -uroot -pnagiosxi --table|grep nagios_log
| nagios_logentries | NULL |
we had incident since two days cause a lot of server to be unreachable for couple of hours, i am not sure if that affected the logentries to be NULL
I am thinking of running /usr/local/nagiosxi/scripts/repair_databases.sh
could you share the best actions to do?
Thanks.
mariadb problem.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: mariadb problem.
exp-user1 wrote:I have the following ERROR in mariadb.log file :
200124 9:39:57 [ERROR] mysqld: Table './nagios/nagios_logentries' is marked as crashed and last (automatic?) repair failed
Yes, this is the best action to do to fix the crashed tables.exp-user1 wrote: I am thinking of running /usr/local/nagiosxi/scripts/repair_databases.sh
could you share the best actions to do?
Code: Select all
/usr/local/nagiosxi/scripts/repair_databases.sh