"
运行环境:<span style=""font-size:13.3333px;"">Redhat上搭建Vmare里运行Centos安装cacti(已经启动)
<table style=""width:100%;"" cellpadding=""2"" cellspacing=""0"" border=""1"" bordercolor=""#000000""> CentOS Vmware Redhat"
开启Configuration-Settings-General-Poller Specific Logging-Poller Logging Level-DEBUG-Save
查看Utilities-System Utilities-View Cacti Log File
11:20:15 AM - SPINE: Poller[0] ERROR: SQL Failed! Error:'145', Message:'Table './cacti/poller_output' is marked as crashed and should be repaired', SQL Fragment:'INSERT INTO poller_output (local_data_id, rrd_name, time, output) VALUES (2668,'cpu','2016-06-14 11:20:14','3
修复数据库
###### >今日Cacti不显示流量,有如下 告警信息: Mysql中数据表修复:
#用REPAIR TABLE方式修复,语法:REPAIR TABLE 表名 [选项]
#进入Mysql数据库:
C:\AppServ\MySQL\bin>mysql -u root -p
Enter password: **************
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 87
Server version: 5.0.45-community-nt-log MySQL Community Edition (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
#显示所有数据库:
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| cacti |
| mysql |
| phpmyadmin |
| test |
+--------------------+
5 rows in set (0.00 sec)
mysql>
#连接损坏表所在的数据库:
mysql> use cacti;
Database changed
#查看当前连接的数据库:
mysql> select database();
+------------+
| database() |
+------------+
| cacti |
+------------+
1 row in set (0.00 sec)
# REPAIR TABLE修复数据表
mysql> REPAIR TABLE poller_item;
+-------------------+--------+----------+----------+
| Table | Op | Msg_type | Msg_text |
+-------------------+--------+----------+----------+
| cacti.poller_item | repair | status | OK |
+-------------------+--------+----------+----------+
1 row in set (0.02 sec)
mysql>
修复成功。
如果修复失败,可以尝试用USE_FRM选项,例:
mysql> REPAIR TABLE poller_item USE_FRM;
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。