中文字幕av专区_日韩电影在线播放_精品国产精品久久一区免费式_av在线免费观看网站

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

ganglia3.6.1+jmxtrans+strom-0.9.4集成

發布時間:2020-06-29 04:11:53 來源:網絡 閱讀:4452 作者:tjbklx33 欄目:大數據

1、安裝ganglia參考之前的一篇博客(以下示例使用ganglia組播方式,單播方式大家自己嘗試)

http://chengyanbin.blog.51cto.com/3900113/1591373

2、安裝jmxtrans

http://chengyanbin.blog.51cto.com/3900113/1654754

3、安裝storm

http://chengyanbin.blog.51cto.com/3900113/1654757

4、修改storm配置文件storm..yaml

###nimbus config
 nimbus.childopts: "-verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.port=12345 -Xmx1024m"

###supervisor config
 supervisor.childopts: "-verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.port=12346 -Xmx256m"

5、為jmxtrans增加兩個json文件

分別獲取nimbus和supervisor節點的jvm信息,以下文件僅列舉了部分參數,如果有需要可以增加queries中的數據,以監控更多的參數,具體的MBean的參數,可以通過jconsole來查看

nimbus.json

{
    "servers": [
        {
        		"host": "master",
            "port": "12345",
            "queries": [
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "nimbus",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:type=Memory",
                    "resultAlias": "nimbus.heap",
                    "attr": [
                        "ObjectPendingFinalizationCount"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "nimbus",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:name=Copy,type=GarbageCollector",
                    "resultAlias": "nimbus.gc",
                    "attr": [
                        "CollectionCount",
                        "CollectionTime"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "nimbus",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:name=Code Cache,type=MemoryPool",
                    "resultAlias": "nimbus.threads",
                    "attr": [
                        "CollectionUsageThreshold",
                        "CollectionUsageThresholdCount",
                        "UsageThreshold",
                        "UsageThresholdCount"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "nimbus",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:type=Runtime",
                    "resultAlias": "nimbus.runtime",
                    "attr": [
                        "StartTime",
                        "Uptime"
                    ]
                }
            ],
            "numQueryThreads": 2
        }
    ]
}

supervisor.json

{
    "servers": [
        {
        		"host": "node1",
            "port": "12346",
            "queries": [
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "supervisor",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:type=Memory",
                    "resultAlias": "supervisor.heap",
                    "attr": [
                        "ObjectPendingFinalizationCount"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "supervisor",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:name=Copy,type=GarbageCollector",
                    "resultAlias": "supervisor.gc",
                    "attr": [
                        "CollectionCount",
                        "CollectionTime"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "supervisor",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:name=Code Cache,type=MemoryPool",
                    "resultAlias": "supervisor.threads",
                    "attr": [
                        "CollectionUsageThreshold",
                        "CollectionUsageThresholdCount",
                        "UsageThreshold",
                        "UsageThresholdCount"
                    ]
                },
                {
                    "outputWriters": [
                        {
                            "@class": "com.googlecode.jmxtrans.model.output.GangliaWriter",
                            "settings": {
                                "groupName": "supervisor",
                                "host": "239.2.11.71",
                                "port": "8649"
                            }
                        }
                    ],
                    "obj": "java.lang:type=Runtime",
                    "resultAlias": "supervisor.runtime",
                    "attr": [
                        "StartTime",
                        "Uptime"
                    ]
                }
            ],
            "numQueryThreads": 2
        }
    ]
}

兩個json文件一定要注意host是主機名,如果寫ip的話,在ganglia里同一個節點會有兩個顯示,看著有點別扭,大家都統一使用hostname就好.ganglia的gmnod和gmetad不需要重啟,用自動收集。

說明:

    修改json文件需要重新啟動jmxtrans,查看jmxtrans日志/var/log/jmxtrans/jmxtrans.log.

    service jmxtrans restart

下面來張ganglia的主界面,監控兩個節點

ganglia3.6.1+jmxtrans+strom-0.9.4集成

上圖顯示不出來監控指標,就放下面來了,可以看到supervisor的監控數據已經收集到ganglia里了。

ganglia3.6.1+jmxtrans+strom-0.9.4集成

下圖搞了master節點的頁面,可以看到nimbus group的監控數據已經顯示,node1節點的supervisor group懶得上圖了,大家可以明白了,不明白的去面壁去ganglia3.6.1+jmxtrans+strom-0.9.4集成

ganglia3.6.1+jmxtrans+strom-0.9.4集成


向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

广德县| 尖扎县| 伊通| 临颍县| 泰安市| 清远市| 沅江市| 乃东县| 雅安市| 延吉市| 宁津县| 久治县| 漳浦县| 台江县| 芦山县| 天峻县| 平江县| 班戈县| 阿克陶县| 濮阳县| 子长县| 滨海县| 桂阳县| 武定县| 盐源县| 三穗县| 建水县| 博白县| 玉林市| 全南县| 青州市| 云霄县| 杨浦区| 克拉玛依市| 鞍山市| 元江| 晴隆县| 丰城市| 台中市| 平阴县| 宜宾市|