增加cacti监控对象时导致无数据无图形出现

生产环境:

操作系统:CentOS release 6.8 (Final)

数据库:mysql 5.5.49-cll-lve

问题:在众多Cacti监控的对象中,由于增加一台服务器增加了一个了监控对象Windows系统,导致cacti在监控所有对象中仅有1个对象出图出数据。

分析:

1.图像没有生成,运行# /usr/bin/php /var/www/html/cacti/poller.php --force #出现数据了吗?
2.权限问题,修改权限#chmod 777 -R /var/www/html/cacti/rra  #没有权限吗?
3.数据库表有损坏。#需要修复数据库吗?

4.重新启动snmp服务。

5.使用snmpwalk 获取各种信息。

出现问题之后,我们要通过检查错误日志来分析问题所在。

[[email protected] log]# sz  cacti.log   #下载日志分析

rz

zmodem trl+C

100% 1211481 KB 6478 KB/s 00:03:07       0 Errorss

[[email protected] log]# tail  -n 200 cacti.log  #查看文本文件末尾n行,请查看附件代码

09/07/2016 03:53:02 PM - CMDPHP: Poller[0] Host[2] DS[15] WARNING: Result from SERVER not valid.  Partial Result: U

09/07/2016 03:53:02 PM - CMDPHP: Poller[0] Host[2] DS[12] WARNING: Result from SERVER not valid.  Partial Result: U

……………………….

[[email protected] ~]# mysqlcheck  --auto-repair  --databases  cacti -p

Enter password:

cacti.cdef                                         OK

cacti.cdef_items                                   OK

cacti.colors                                       OK

cacti.data_input                                   OK

cacti.data_input_data

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.data_input_fields                            OK

cacti.data_local

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.data_template                                OK

cacti.data_template_data

warning  : 3 clients are using or haven‘t closed the table properly

status   : OK

cacti.data_template_data_rra

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.data_template_rrd

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.graph_local

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.graph_template_input                         OK

cacti.graph_template_input_defs

warning  : 1 client is using or hasn‘t closed the table properly

status   : OK

cacti.graph_templates                              OK

cacti.graph_templates_gprint                       OK

cacti.graph_templates_graph

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.graph_templates_item

warning  : 2 clients are using or haven‘t closed the table properly

status   : OK

cacti.graph_tree                                   OK

cacti.graph_tree_items                             OK

cacti.host

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.host_graph                                   OK

cacti.host_snmp_cache

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.host_snmp_query                              OK

cacti.host_template                                OK

cacti.host_template_graph

warning  : 1 client is using or hasn‘t closed the table properly

status   : OK

cacti.host_template_snmp_query                     OK

cacti.plugin_config                                OK

cacti.plugin_db_changes                            OK

cacti.plugin_discover_hosts

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.plugin_discover_template                     OK

cacti.plugin_hooks                                 OK

cacti.plugin_notification_lists                    OK

cacti.plugin_realms                                OK

cacti.plugin_thold_contacts                        OK

cacti.plugin_thold_host_failed                     OK

cacti.plugin_thold_log

warning  : 5 clients are using or haven‘t closed the table properly

status   : OK

cacti.plugin_thold_template_contact                OK

cacti.plugin_thold_threshold_contact               OK

cacti.poller                                       OK

cacti.poller_command

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.poller_item

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.poller_output                                OK

cacti.poller_output_rt

warning  : 3 clients are using or haven‘t closed the table properly

status   : OK

cacti.poller_reindex

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.poller_time                                  OK

cacti.rra                                          OK

cacti.rra_cf                                       OK

cacti.settings

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.settings_graphs                              OK

cacti.settings_tree                                OK

cacti.snmp_query                                   OK

cacti.snmp_query_graph                             OK

cacti.snmp_query_graph_rrd                         OK

cacti.snmp_query_graph_rrd_sv                      OK

cacti.snmp_query_graph_sv                          OK

cacti.syslog                                       OK

cacti.syslog_alert                                 OK

cacti.syslog_facilities                            OK

cacti.syslog_host_facilities                       OK

cacti.syslog_hosts                                 OK

cacti.syslog_incoming                              OK

cacti.syslog_logs                                  OK

cacti.syslog_priorities                            OK

cacti.syslog_remove                                OK

cacti.syslog_removed                               OK

cacti.syslog_reports                               OK

cacti.syslog_statistics                            OK

cacti.test                                         OK

cacti.thold_data

warning  : 6 clients are using or haven‘t closed the table properly

status   : OK

cacti.thold_template                               OK

cacti.user_auth                                    OK

cacti.user_auth_perms                              OK

cacti.user_auth_realm                              OK

cacti.user_log

warning  : 4 clients are using or haven‘t closed the table properly

status   : OK

cacti.version

[[email protected] /]# mysqlcheck --auto-repair --database cacti -p  #修复数据库

Warning: Using unique option prefix database instead of databases is deprecated and will be removed in a future release. Please use the full name instead.

Enter password:

cacti.cdef                                         OK

cacti.cdef_items                                   OK

cacti.colors                                       OK

cacti.data_input                                   OK

cacti.data_input_data                              OK

cacti.data_input_fields                            OK

cacti.data_local                                   OK

cacti.data_template                                OK

cacti.data_template_data                           OK

cacti.data_template_data_rra                       OK

cacti.data_template_rrd                            OK

cacti.graph_local                                  OK

cacti.graph_template_input                         OK

cacti.graph_template_input_defs                    OK

cacti.graph_templates                              OK

cacti.graph_templates_gprint                       OK

cacti.graph_templates_graph                        OK

cacti.graph_templates_item                         OK

cacti.graph_tree                                   OK

cacti.graph_tree_items                             OK

cacti.host                                         OK

cacti.host_graph                                   OK

cacti.host_snmp_cache                              OK

cacti.host_snmp_query                              OK

cacti.host_template                                OK

cacti.host_template_graph                          OK

cacti.host_template_snmp_query                     OK

cacti.plugin_config                                OK

cacti.plugin_db_changes                            OK

cacti.plugin_discover_hosts                        OK

cacti.plugin_discover_template                     OK

cacti.plugin_hooks                                 OK

cacti.plugin_notification_lists                    OK

cacti.plugin_realms                                OK

cacti.plugin_thold_contacts                        OK

cacti.plugin_thold_host_failed                     OK

cacti.plugin_thold_log                             OK

cacti.plugin_thold_template_contact                OK

cacti.plugin_thold_threshold_contact               OK

cacti.poller                                       OK

cacti.poller_command                               OK

cacti.poller_item                                  OK

cacti.poller_output                                OK

cacti.poller_output_rt                             OK

cacti.poller_reindex                               OK

cacti.poller_time                                  OK

cacti.rra                                          OK

cacti.rra_cf                                       OK

cacti.settings                                     OK

cacti.settings_graphs                              OK

cacti.settings_tree                                OK

cacti.snmp_query                                   OK

cacti.snmp_query_graph                             OK

cacti.snmp_query_graph_rrd                         OK

cacti.snmp_query_graph_rrd_sv                      OK

cacti.snmp_query_graph_sv                          OK

cacti.syslog                                       OK

cacti.syslog_alert                                 OK

cacti.syslog_facilities                            OK

cacti.syslog_host_facilities                       OK

cacti.syslog_hosts                                 OK

cacti.syslog_incoming                              OK

cacti.syslog_logs                                  OK

cacti.syslog_priorities                            OK

cacti.syslog_remove                                OK

cacti.syslog_removed                               OK

cacti.syslog_reports                               OK

cacti.syslog_statistics                            OK

cacti.test                                         OK

cacti.thold_data                                   OK

cacti.thold_template                               OK

cacti.user_auth                                    OK

cacti.user_auth_perms                              OK

cacti.user_auth_realm                              OK

cacti.user_log                                     OK

cacti.version                                      OK

[[email protected] /]# /usr/bin/php  /var/www/html/cacti/poller.php --force  #生成对象

09/07/2016 06:03:56 PM - SYSTEM STATS: Time:0.4219 Method:cmd.php Processes:4 Threads:N/A Hosts:10 HostsPerProcess:3 DataSources:0 RRDsProcessed:0

[[email protected] /]# chmod 777 -R  rra   #设置权限

[[email protected] /]# service snmpd restart  #重新启动服务

[[email protected] /]# snmpwalk -v  2c 117.40.***.*   -c public  #收集各种信息

此次增加cacti对象导致两个问题,一个是导致数据库发生错误,另一个是snmp运行服务的问题。

时间: 2024-09-29 15:29:20

增加cacti监控对象时导致无数据无图形出现的相关文章

增加cacti监控对象时导致数据库出问题

生产环境: 数据库:mysql 5.5.49-cll-lve 问题:在众多Cacti监控的对象中,由于增加了监控对象nginx,导致cacti在监控所有对象中仅有1个对象出图出数据. 分析: 1.systemutilities –>Rebuild poller cache #需要重建cache吗?2.系统时间不准确,重新设置时间  #需要更新服务器时间吗?3.图像没有生成,运行 # /usr/bin/php /var/www/html/cacti/poller.php --force #出现数据

Cacti监控图像增加对redis多实例监控的支持

1.下载percona模板,解压 wget http://www.percona.com/redir/downloads/percona-monitoring-plugins/1.0.1/percona-monitoring-plugins-1.0.1.tar.gz 2.在redis的默认模板配置文件的基础上增加选项port2,用户在新建redis监控图像时要求填写redis端口号,不填的话就是默认的6379,ss_get_by_ssh.php脚本通过port2选项连接指定端口的redis实例:

验证当多个类之间有继承关系时,创建子类对象会导致父类初始化块的执行。

结果:当多个类之间有继承关系时,创建子类对象会导致父类初始化块的执行.

Mysql5.7.11 安装 cacti0.8.8f ,在导入cacti.sql数据库时出现下记错误,导致数据库导入终止: ERROR 1067 (42000) at line 1847: Invalid default value for 'status_fail_date'

解决方法:vim /etc/my.cnf 文件,加入 : sql-mode="NO_ENGINE_SUBSTITUTION" , Systemctl restart mysqld 进入mysql的之后可执行: select @@sql_mode 查询当前使用的sql_mode是什么 Mysql5.7.11 安装 cacti0.8.8f ,在导入cacti.sql数据库时出现下记错误,导致数据库导入终止: ERROR 1067 (42000) at line 1847: Invalid

Cacti监控服务器配置教程(基于CentOS+Nginx+MySQL+PHP环境搭建)

具体案例:局域网内有两台主机,一台Linux.一台Windows,现在需要配置一台Cacti监控服务器对这两台主机进行监控环境说明:1.Linux主机操作系统:CentOS 6.2IP地址:192.168.21.164子网掩码:255.255.255.0网关:192.168.21.2DNS:8.8.8.8 8.8.4.42.Windows主机操作系统:Windows Server 2003IP地址:192.168.21.130子网掩码:255.255.255.0网关:192.168.21.2DN

使用Visual VM监控运行时的项目

1.1 Visual VM简介 VisualVM 提供在 Java 虚拟机 (Java Virutal Machine, JVM) 上运行的 Java 应用程序的详细信息.在 VisualVM 的图形用户界面中,您可以方便.快捷地查看多个 Java 应用程序的相关信息.(摘自官方) 简单说来,VisualVM是一种集成了多个JDK命令行工具的可视化工具,它能为您提供强大的分析能力.所有这些都是免费的!它囊括的命令行工具包括jstat, JConsole, jstack, jmap 和 jinfo

实战2 Cacti监控Localhost和Remote Host

上篇博文主要讲解了cacti监控host主机,由于上篇博文cacti的版本也不是最新的!所以在实战2更新了cacti的版本,并添加了监控远程服务器和优化轮询 实战2 重点 一.新版cacti监控host 二.新版cacti监控Remote Host 三.新版cacti优化spine轮询 附加 四.网卡流量和存储挂在盘 一.新版cacti监控host 1.安装lamp平台 [[email protected] ~]# yum install -y httpd php php-mysql php-s

cacti监控部署与配置

cacti是一套基于PHP,mysql,SNMP及RRDTool开发的网络流量测试图形分析工具 cacti是通过snmpget来获取数据,使用RRDtool绘画图形 ,而且完全可以不需要了解RRDtool复杂的参数 ,它提供了非常强大的数据和用户管理功能,可以指定每个用户能查看树状结构,host以及任何一张图,还可以与LDAP结合进行用户验证,同时也能自己增加模板,功能非常强大完善.界面 友好,软件cacti的发展是基于让RRTool使用这更方便的使用该软件,除了基本 的SNMP的流量更系统咨询

CentOS上配置Cacti监控MySQL

防伪码:即使没有辉煌的未来.如果能有无悔的往昔.   第九章 CentOS上配置Cacti监控MySQL 前言:在企业网络运维过程中,管理员必须随时关注服务器和网络的运行状况.以便及时发现问题,尽可能减少故障的发生.当网络中的设备.服务器等数量较多时,为了更加方便.快捷的获得各种监控信息,通常会借助于一些集中检测软件.本章将以著名的Cacti套件为例,介绍服务器集中监控体系的构建和使用. 一.Cacti官方简介: 1.Cacti是通过 snmpget来获取数据,使用 RRDtool绘画图形,而且