angelcai1986 发表于 2011-9-28 14:35:47

cacti监控mysql

一、被监控主机配置
  1)、vi /etc/snmp/snmpd.conf
  更改com2sec notConfigUser default public
  改为com2sec notConfigUser 127.0.0.1 public 注:如果是其它被监控主机,这里应该为监控服务器。
  2)、更改access notConfigGroup "" any noauth exact systemview none none
  改为access notConfigGroup "" any noauth exact all none none
  3)、#view all included .1 80
  将前面的 # 注释 去掉。
  保存退出
  启动snmpd服务 :
  chkconfig snmpd on&& service snmpd start
  mysql>GRANT PROCESS, SUPER, REPLICATION CLIENT ON *.* TO 'cacti'@'192.168.0.17' identified by 'cacti';
  mysql>grant process,super on *.* to 'cacti'@'192.168.0.%' identified by 'cacti';
  二、监控服务器配置
  mkdir -p /usr/local/apache/htdocs/cacti/cache/
  chmod 777 /usr/local/apache/htdocs/cacti/cache/
  修改ss_get_mysql_stats.php 文件 第30行
  $mysql_user = 'cacti';
  $mysql_pass = 'cacti';
  $cache_dir = "/usr/local/apache/htdocs/cacti/cache/";
  三,模板导入在cacti管理界面(Import Templates)导入cacti_host_template_x_db_server_ht_0.8.6i.xml。
本文由:SKF轴承 http://wwww.9-zc.com 整理发布
页: [1]
查看完整版本: cacti监控mysql