Frage

Ireceived eine Ausfallzeit Warnung von Nagios, dass MySQL auf einem Host war unten. Ich angemeldet an den Host und fand die folgenden Fehler in der mysql error.log-Datei. Was sind die richtigen Schritte, um dies zu beheben?

root@ubuntu:/var/log# tail -f mysql/error.log
101202 11:09:21 [ERROR] Can't open the mysql.plugin table. Please run 
                        mysql_upgrade to create it.
101202 11:09:21  InnoDB: Started; log sequence number 0 44233
101202 11:09:21 [ERROR] /usr/sbin/mysqld: Can't find file: './mysql/host.frm' 
                        (errno: 13)
101202 11:09:21 [ERROR] Fatal error: Can't open and lock privilege tables: 
                        Can't find file: './mysql/host.frm' (errno: 13)
101202 11:09:51 [Note] Plugin 'FEDERATED' is disabled.
                       /usr/sbin/mysqld: Can't find file: './mysql/plugin.frm' 
                       (errno: 13)
101202 11:09:51 [ERROR] Can't open the mysql.plugin table. Please run 
                        mysql_upgrade to create it.
101202 11:09:52  InnoDB: Started; log sequence number 0 44233
101202 11:09:52 [ERROR] /usr/sbin/mysqld: Can't find file: './mysql/host.frm' 
                        (errno: 13)
101202 11:09:52 [ERROR] Fatal error: Can't open and lock privilege tables: 
                        Can't find file: './mysql/host.frm' (errno: 13)
101202 11:10:22 [Note] Plugin 'FEDERATED' is disabled.
                       /usr/sbin/mysqld: Can't find file: './mysql/plugin.frm' 
                       (errno: 13)
101202 11:10:22 [ERROR] Can't open the mysql.plugin table. Please run 
                        mysql_upgrade to create it.
101202 11:10:22  InnoDB: Started; log sequence number 0 44233
101202 11:10:22 [ERROR] /usr/sbin/mysqld: Can't find file: './mysql/host.frm' 
                        (errno: 13)
101202 11:10:22 [ERROR] Fatal error: Can't open and lock privilege tables: 
                        Can't find file: './mysql/host.frm' (errno: 13)
War es hilfreich?

Lösung

Abbildung heraus, warum MySQL kann seine Tabellen nicht finden. Gehen Sie auf die MySQL-Datenverzeichnis und das Aussehen für die mysql-Unterverzeichnis (entsprechend der mysql Datenbank, die Dinge wie Benutzer enthält, Procs, Privilegien, etc.). Vielleicht hat jemand löschte die mysql Datenbank. Vielleicht hat jemand überschreibt Ihre my.cnf-Konfigurationsdatei mit einem auf das falsche Datenverzeichnis.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top