手机版
你好,游客 登录 注册 搜索
背景:
阅读新闻

在 CentOS上安装配置 Ganglia-3.4.0

[日期:2012-11-14] 来源:Linux社区  作者:chenjiuling [字体:大 中 小]

(4)安装配置 rrdtool
 
# cd /opt
 
#wget http://down1.chinaunix.net/distfiles/rrdtool-1.4.5.tar.gz
 
# tar xvf rrdtool-1.4.5.tar.gz
 
# cd rrdtool-1.4.5
 
# ./configure –prefix=/usr/local/rrdtool –enable-shared
 
# make && make install
 
将rrdtool的命令加入配置环境下:
 
# vi /etc/profile
 
export PATH=$PATH:/usr/local/rrdtool/bin
 
#source /etc/profile
 
(5)安装配置其他所要依赖的包:
 
# yum install -y expat expat-devel pcre pcre-devel
 
# cd /opt
 # wget http://mirror.bit.edu.cn/apache/apr/apr-1.4.6.tar.gz
 #tar zxf apr-1.4.6.tar.gz
 #cd apr-1.4.6
 # ./configure;make;make install
#cd ..
 
# wget http://download.savannah.gnu.org/releases/confuse/confuse-2.7.tar.gz
 # tar zxf confuse-2.7.tar.gz
 # cd confuse-2.7
 # ./configure CFLAGS=-fPIC --disable-nls ;make;make install
# cd ..
 
(6)Ganglia的安装
 好了,终于要安装ganglia了,下面开始:
 
#wget http://nchc.dl.sourceforge.net/project/ganglia/ganglia%20monitoring%20core/3.4.0/ganglia-3.4.0.tar.gz
 
# tar zxf ganglia-3.4.0.tar.gz
 # cd ganglia-3.4.0
 
# ./configure --prefix=/opt/modules/ganglia --with-static-modules --enable-gexec --enable-status --with-gmetad --with-python=/usr --with-librrd=/usr/local/rrdtool --with-libexpat=/usr --with-libconfuse=/usr/local --with-libpcre=/usr/local
 
 


# make && make install
 # cd gmetad
 # cp gmetad.conf /opt/modules/ganglia/etc/
 # cp gmetad.init /etc/init.d/gmetad
 
打开gmetad的配置文件,修改如下内容:
 # vi /etc/init.d/gmetad
 
将GMETAD=/usr/bin/gmetad
 
 改为GMETAD=/opt/modules/ganglia/sbin/gmetad
 
# chkconfig --add gmetad
 # route add -host 239.2.11.71 dev eth0
 
# mkdir –p /var/lib/ganglia/rrds
 
# chown nobody:nobody /var/lib/ganglia/
 
#vi /opt/modules/ganglia/etc/gmetad.conf
 
data_source "ling" 10.100.10.10
 
在最后添加如下内容:
 
setuid_username "root"
 
rrd_rootdir "/usr/local/rrdtool"
 
说明:这里的”ling”表示的是集群的名称,后面的内容是这个集群中所包含的主机信息,也就是要监控的主机ip。
 
# service gmetad start
 
# netstat –tnlp |grep gmetad
 
tcp        0      0 0.0.0.0:8651                0.0.0.0:*                  LISTEN      29583/gmetad       

tcp        0      0 0.0.0.0:8652                0.0.0.0:*                  LISTEN      29583/gmetad 

linux
相关资讯       Ganglia  Ganglia安装  Ganglia配置 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款