zoukankan      html  css  js  c++  java
  • ganglia监控hadoop2.0配置方法

    ganglia监控hadoop2.0配置方法
    前提:hadoop2.0集群已安装ganglia监控工具
    第一步:
    Hadoop用户登录集群每一个节点,
    修改文件:vi /opt/hadoop-2.0.0-cdh4.5.0/etc/hadoop/hadoop-metrics2.properties
    将文件内容修改为如下内容:(注释或者删除默认配置)
    *.sink.ganglia.class=org.apache.hadoop.metrics2.sink.ganglia.GangliaSink31
    *.sink.ganglia.period=10
    *.sink.ganglia.slope=jvm.metrics.gcCount=zero,jvm.metrics.memHeapUsedM=both
    *.sink.ganglia.dmax=jvm.metrics.threadsBlocked=70,jvm.metrics.memHeapUsedM=40

    #注意端口是你的gmetad配置的端口
    namenode.sink.ganglia.servers=239.2.11.71:8661
    resourcemanager.sink.ganglia.servers=239.2.11.71:8661
    datanode.sink.ganglia.servers=239.2.11.71:8661
    nodemanager.sink.ganglia.servers=239.2.11.71:8661
    maptask.sink.ganglia.servers=239.2.11.71:8661
    reducetask.sink.ganglia.servers=239.2.11.71:8661

    第二步:
    在master节点重启hadoop集群
    hadoop用户执行:
    sh /opt/zookeeper-3.4.5-cdh4.4.0/bin/zkServer.sh restart
    sh /opt/hadoop-2.0.0-cdh4.5.0/sbin/hadoop-daemon.sh start journalnode
    sh /opt/hadoop-2.0.0-cdh4.5.0/sbin/stop-dfs.sh
    sh /opt/hadoop-2.0.0-cdh4.5.0/bin-mapreduce1/stop-mapred-ha.sh
    sh /opt/hadoop-2.0.0-cdh4.5.0/sbin/start-dfs.sh
    sh /opt/hadoop-2.0.0-cdh4.5.0/bin-mapreduce1/start-mapred-ha.sh
    sh /opt/hadoop-2.0.0-cdh4.5.0/bin/hdfs haadmin -DfSHAadmin -failover nn1 nn0
    重启ganglia的gmaster进程
    Root用户在172.16.2.30执行:
    service gmaster restart

  • 相关阅读:
    VS2015 C#取消最大化按钮,设置鼠标不可调整窗体大小
    C++调用C#编写的DLL【转】
    C#封装成DLL,并在C#中调用
    ubuntu永久修改主机名
    Anaconda3的安装和汉化
    windows下面安装Python和pip教程
    pip install bs4安装失败
    Sublime text 3中文汉化教程
    Vmware安装ubuntu详细教程
    Sublime text3修改tab键为缩进为四个空格
  • 原文地址:https://www.cnblogs.com/qinche/p/3529426.html
Copyright © 2011-2022 走看看