ganglia安装 by frank

作者是frank。

1.安装epel
rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
2.
yum remove rrdtool-1.3.8-6.el6.i686
yum install rrdtool-1.2.27-3.el5.i386

yum install ganglia ganglia-gmetad ganglia-gmond ganglia-web httpd php

安装perl

yum install  perl

默认情况下,Ganglia使用多播或UDP来传递信息。
项目安装中,主节点IP地址是 10.64.2.97, 端口号是8649。编辑/etc/gmond.conf如下

cluster {
name = "My Cluster"
owner = "Me"
latlong = "unspecified"
url = "unspecified"
}
udp_send_channel {
host = 10.64.2.97
port = 8649
ttl = 1
}
udp_recv_channel {
port = 8649
}
注意,在/etc/sysconfig/iptables中配置允许本地局域网内网接口无限制访 问。

1
-A RH-Firewall-1-INPUT -s 10.64.2.0/255.255.255.0 -j ACCEPT
配置服务器启动时启动服务gmond
1
2
chkconfig --levels 235 gmond on
service gmond start
配置/etc/gmetad.conf定义数据源
1
data_source "My Cluster" 10.64.2.97:8649
配置服务器启动时启动服务gmetad
1
2
chkconfig --levels 235 gmetad on
service gmetad start
配置httpd服务启动时启动
1
2
chkconfig --levels 235 httpd on
service httpd start
selinux设置
setenforce 0

继续设置:

配置apache的文档根目录:

vim /etc/httpd/conf/httpd.conf

找到:DocumentRoot "/var/www/html"

替换成:DocumentRoot "/usr/share/ganglia"

找到:<Directory "/var/www/html">

替换成:<Directory "/usr/share/ganglia">

找到:DirectoryIndex index.html index.html.var

替换成:DirectoryIndex index.html index.html.var index.php default.php

上一篇:关于字符编码:ascii、unicode与utf-8


下一篇:Java中集合List,Map和Set的区别