wuliuwang 发表于 2019-1-11 08:58:23

cacti不绘制数据图

  Cacti不绘制监控图
  刚上班,黄教主就叫:xxx,Cacti有问题啦!!!怎么的啦?原来是Cacti不绘制监控图了。
  The steps for save issue:
  1:出问题了,首先看相关服务日志:
  #cd /var/www/html/cacti/log
  #tail -fn100 cacti.log
  09/18/2012 10:10:08 AM - CMDPHP: Poller ERROR: SQL Assoc Failed!, Error:'1017', SQL:"selectpoller_output.output,poller_output.time,UNIX_TIMESTAMP(poller_output.time) as unix_time,poller_output.local_data_id,poller_item.rrd_path,poller_item.rrd_name,poller_item.rrd_numfrom (poller_output,poller_item)where (poller_output.local_data_id=poller_item.local_data_id and poller_output.rrd_name=poller_item.rrd_name)LIMIT 10000"
  09/18/2012 10:10:08 AM - CMDPHP: Poller ERROR: SQL Assoc Failed!, Error:'1017', SQL:"selectpoller_output.output,poller_output.time,UNIX_TIMESTAMP(poller_output.time) as unix_time,poller_output.local_data_id,poller_item.rrd_path,poller_item.rrd_name,poller_item.rrd_numfrom (poller_output,poller_item)where (poller_output.local_data_id=poller_item.local_data_id and poller_output.rrd_name=poller_item.rrd_name)LIMIT 10000"
  发现有N行这样的ERROR关于poller_output这张表的,后来查了一下,网上N多人说是此磁盘满了(或其所在分区满了),也没心思查了,先看立刻解决问题的方法吧!!!
  2:登录cacti所在的数据库
  #mysql -ucacti -pcacti cacti
  mysql> select count(*) from poller_output;
  ERROR 1017 (HY000): Can't find file: 'poller_output' (errno: 2)
  出现大概如上的错误,查询都没法子,先把这张表的数据清空了。
  mysql> truncate table poller_output;
  Query OK, 0 rows affected (0.02 sec)
  mysql> select count(*) from poller_output;
  +----------+
| count(*) |
+----------+
| 0 |
+----------+
1 row in set (0.00 sec)
  OK,一切恢复正常了,稍等监控图也会出来啦!!!
  看下cacti的日志:
  09/18/2012 11:00:05 AM - PHPSVR: Poller WARNING: Script Server terminated with signal 'SIGSEGV' in file:'ss_host_disk.php', function:'ss_host_disk', params:'172.31.10.11 23 2:161:500:1:10:51auto:::::: get total 38'
  09/18/2012 11:00:09 AM - SYSTEM STATS: Time:7.3854 Method:spine Processes:10 Threads:10 Hosts:25 HostsPerProcess:3 DataSources:548 RRDsProcessed:455
  09/18/2012 11:00:09 AM - SYSTEM THOLD STATS: Time:0.1994 Tholds:44 DownHosts:0
  09/18/2012 11:05:10 AM - SYSTEM STATS: Time:8.1963 Method:spine Processes:10 Threads:10 Hosts:25 HostsPerProcess:3 DataSources:548 RRDsProcessed:455
  一切正常了》



页: [1]
查看完整版本: cacti不绘制数据图