单层gmetad高可用
虽然gmetad可以多层,但是层层gmetad都需要开启gweb,还是很麻烦。如果只是担心一个gmetad不安全,可以做成gmetad高可用,但是我还不知道有没有想hadoop ha那样自动failover的办法。
资源安排:
1.
hdp1:gmetad、gmond、gweb
hdp2:gmetad、gmond、gweb
hdp3:gmond
配置目的:
hdp1和hdp2的gmetad、gweb高可用,每个节点的gweb都可以展示整个集群的数据
hdp1、2、3均属于一个集群
配置文件:
hdp3——gmond.conf:
cluster {
name = "hdp3"
owner = "unspecified"
latlong = "unspecified"
url = "unspecified"
}
/* The host section describes attributes of the host, like the location */
host {
location = "unspecified"
}
/* Feel free to specify as many udp_send_channels as you like. Gmond
used to only support having a single channel */
udp_send_channel {
#bind_hostname = yes # Highly recommended, soon to be default.
# This option tells gmond to use a source address
# that resolves to the machine's hostname. Without
# this, the metrics may appear to come from any
# interface and the DNS names associated with
# those IPs will be used to create the RRDs.
#mcast_join = 239.2.11.71
host = hdp1
port = 8649
ttl = 1
}
udp_send_channel {
#bind_hostname = yes # Highly recommended, soon to be default.
# This option tells gmond to use a source address
# that resolves to the machine's hostname. Without
# this, the metrics may appear to come from any
# interface and the DNS names associated with
# those IPs will be used to create the RRDs.
#mcast_join = 239.2.11.71
host = hdp2
port = 8649
ttl = 1
}
/* You can specify as many udp_recv_channels as you like as well. */
udp_recv_channel {
#mcast_join = 239.2.11.71
#port = 8649
#bind = 239.2.11.71
#retry_bind = true
# Size of the UDP buffer. If you are handling lots of metrics you really
# should bump it up to e.g. 10MB or even higher.
# buffer = 10485760
}
/* You can specify as many tcp_accept_channels as you like to share
an xml description of the state of the cluster */
tcp_accept_channel {
#port = 8649
# If you want to gzip XML output
gzip_output = no
}
hdp1——gmond.conf:
cluster {
name = "hdp3"
owner = "unspecified"
latlong = "unspecified"
url = "unspecified"
}
/* The host section describes attributes of the host, like the location */
host {
location = "unspecified"
}
/* Feel free to specify as many udp_send_channels as you like. Gmond
used to only support having a single channel */
udp_send_channel {
#bind_hostname = yes # Highly recommended, soon to be default.
# This option tells gmond to use a source address
# that resolves to the machine's hostname. Without
# this, the metrics may appear to come from any
# interface and the DNS names associated with
# those IPs will be used to create the RRDs.
#mcast_join = 239.2.11.71
host = hdp1
port = 8649
ttl = 1
}
udp_send_channel {
#bind_hostname = yes # Highly recommended, soon to be default.
# This option tells gmond to use a source address
# that resolves to the machine's hostname. Without
# this, the metrics may appear to come from any
# interface and the DNS names associated with
# those IPs will be used to create the RRDs.
#mcast_join = 239.2.11.71
host = hdp2
port = 8649
ttl = 1
}
/* You can specify as many udp_recv_channels as you like as well. */
udp_recv_channel {
#mcast_join = 239.2.11.71
port = 8649
#bind = 239.2.11.71
}
/* You can specify as many tcp_accept_channels as you like to share
an xml description of the state of the cluster */
tcp_accept_channel {
port = 8649
}
hdp1——gmetad.conf:
[root@hdp1 ganglia]# grep -v ^# gmetad.conf
data_source "hdp3" localhost
RRAs "RRA:AVERAGE:0.5:1:244" "RRA:AVERAGE:0.5:24:244" "RRA:AVERAGE:0.5:168:244" "RRA:AVERAGE:0.5:672:244" \
gridname "HDP"
all_trusted on
setuid_username ganglia
xml_port 8651
interactive_port 8652
case_sensitive_hostnames 0
hdp2——gmond.conf:
效仿hdp1的配置即可
效果达到配置目的
2.
hdp1、2、3分属3个集群,hdp1、2为gmetad高可用
则原理为:hdp1、2分别用gmetad去轮询hdp1、2、3的gmond节点(生产中的汇聚节点)
所需配置与单gmetad无异,gmetad复制一份到备份gmetad节点即可
最新文章
- C# Monitoring-network
- 【pom.xml 依赖】使用net.sf.json-lib-2.4-jdk15.jar所需要的其他依赖架包 以及其一直在pom.xml报错的问题
- Eclipse定制右键创建文件快捷菜单
- beeline vs hive cli
- android之‘com.example.android.apis.view’的代码段
- javascript-02
- iOS-scrollview及其子类适配iOS7
- 图像库---Image Datasets---OpenSift源代码---openSurf源代码
- Yii中CDbCriteria常用总结
- java日期工具类(Long型,Date型,yyyyMMdd型)等
- Akka(7): FSM:通过状态变化来转换运算行为
- IO多路复用,同步,异步,阻塞和非阻塞 区别
- Spring BeanDefinitionRegistryPostProcessor BeanPostProcessor作用
- php记录
- PHP 正则表达式资料
- Android SurfaceView概述
- 11、可扩展MySQL+12、高可用
- 基于QT和OpenCV的人脸检測识别系统(2)
- CentOS 7 怎样自动连接网络
- Oracle EBS供应商接口导入(转)
热门文章
- CNN 文本分类模型优化经验——关键点:加卷积层和FC可以提高精度,在FC前加BN可以加快收敛,有时候可以提高精度,FC后加dropout,conv_1d的input维度加大可以提高精度,但是到256会出现OOM。
- JavaScript检查是否包含某个字符
- E20170623-hm
- [Apple开发者帐户帮助]九、参考(2)撤销特权
- DB2锁表或超时解决方案
- php三方网站使用微信公众号推送文章
- 【题解】动态逆序对 [CQOI2011] [P3157] [BZOJ3295] [P1393]
- 解决:xxx is not in the sudoers file.This incident will be reported.的解决方法
- JVM之旅------jvm内存模型
- MySQL 多表批量更新