配置ganglia出了点问题,高手帮帮忙
这几天装了ganglia 3.0.2, 装上后可以正常远程用网页打开, 可以正常显示收集到到计算机的一些资源,但有一个问题一直没法解决,我的服务器有两个IP段,eth0: 192.168.0.100, eth1: 10.10.1.106 这两个IP段分别接的两个交换机,我装上gangia后,它只能显示出10.10.1.X IP段的所以机子,而192.168.0.X段的机子,没法显示,而两个IP段的机子我都已经正常安装了gmond客户端,且都可以正常起动,运行.哪位高手指点一下,是不是我的gmetad.conf的gmond.conf哪些地方设置的不对,非常感受谢!
Gmetad.conf:
data_source "rcmm1" localhost
gridname "RCMM1"
all_trusted on
setuid_username "ren"
其他配置都是默认的
Gmond.conf:
globals {
setuid = yes
user = root
cleanup_threshold = 300 /*secs */
}
cluster {
name = "rcmm1"
}
host {
location = "unspecified"
}
udp_send_channel {
mcast_join = 239.2.11.71
port = 8649
}
udp_recv_channel {
mcast_join = 239.2.11.71
port = 8649
bind = 239.2.11.71
}
tcp_accept_channel {
port = 8649
}
collection_group {
collect_once = yes
time_threshold = 20
metric {
name = "heartbeat"
}
}
collection_group {
collect_once = yes
time_threshold = 1200
metric {
name = "cpu_num"
}
metric {
name = "cpu_speed"
}
metric {
name = "mem_total"
}
/* Should this be here? Swap can be added/removed between reboots. */
metric {
name = "swap_total"
}
metric {
name = "boottime"
}
metric {
name = "machine_type"
}
metric {
name = "os_name"
}
metric {
name = "os_release"
}
metric {
name = "location"
}
}
collection_group {
collect_once = yes
time_threshold = 300
metric {
name = "gexec"
}
}
collection_group {
collect_every = 20
time_threshold = 90
/* CPU status */
metric {
name = "cpu_user"
value_threshold = "1.0"
}
metric {
name = "cpu_system"
value_threshold = "1.0"
}
metric {
name = "cpu_idle"
value_threshold = "5.0"
}
metric {
name = "cpu_nice"
value_threshold = "1.0"
}
metric {
name = "cpu_aidle"
value_threshold = "5.0"
}
metric {
name = "cpu_wio"
value_threshold = "1.0"
}
metric {
name = "cpu_intr"
value_threshold = "1.0"
}
metric {
name = "cpu_sintr"
value_threshold = "1.0"
}
*/
}
collection_group {
collect_every = 20
time_threshold = 90
/* Load Averages */
metric {
name = "load_one"
value_threshold = "1.0"
}
metric {
name = "load_five"
value_threshold = "1.0"
}
metric {
name = "load_fifteen"
value_threshold = "1.0"
}
}
collection_group {
collect_every = 80
time_threshold = 950
metric {
name = "proc_run"
value_threshold = "1.0"
}
metric {
name = "proc_total"
value_threshold = "1.0"
}
}
collection_group {
collect_every = 40
time_threshold = 180
metric {
name = "mem_free"
value_threshold = "1024.0"
}
metric {
name = "mem_shared"
value_threshold = "1024.0"
}
metric {
name = "mem_buffers"
value_threshold = "1024.0"
}
metric {
name = "mem_cached"
value_threshold = "1024.0"
}
metric {
name = "swap_free"
value_threshold = "1024.0"
}
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好像ganglia发现IP有一定的协议,不是你想显示哪个IP就可以显示的.(也许我理解的不正确)
可以在安装gmetad的服务器上
telnet localhost 8651 | grep "ip"
ip为你安装gmond机器的地址,如果有多个可以都试验一下,
看看gmetad能够识别哪一个IP
你的问题
data_source "rcmm1" localhost
localhost是本机,你要根据你安装了gmond的机器来设置它
比如:data_source "rcmm1" 15 10.10.1.2 10.10.1.3……10.10.1.X
data_source "rcmm" 15 192.168.0.1……192.168.0.X
它们默认端口都是8649,你也可以更改它们。在gmond.conf
udp_send_channel {
mcast_join = 239.2.11.71
port = 8648
}
udp_recv_channel {
mcast_join = 239.2.11.71
port = 8648
bind = 239.2.11.71
}
tcp_accept_channel {
port = 8648
在Gmetad.conf:
data_source "rcmm" 15 192.168.0.1:8648
这里只是简单的例子,供你参考。