open-falcon (Mysql監(jiān)控)mymon安裝

原文鏈接:https://github.com/open-falcon/mymon

Introduction

mymon(MySQL-Monitor) -- MySQL數(shù)據(jù)庫(kù)運(yùn)行狀態(tài)數(shù)據(jù)采集腳本,采集包括global status, global variables, slave status等。

Installation

#set $GOPATH and $GOROOT

mkdir -p$GOPATH/src/github.com/open-falcon

cd$GOPATH/src/github.com/open-falcon

git clone https://github.com/open-falcon/mymon.git

cd mymon

go get ./...

go build -o mymonecho'* * * * * cd $GOPATH/src/github.com/open-falcon/mymon && ./mymon -c etc/mon.cfg'>/etc/cron.d/mymon

Configuration

? ? [default]

? ? log_file=mymon.log # 日志路徑和文件名

? ? # Panic 0

? ? # Fatal 1

? ? # Error 2

? ? # Warn 3

? ? # Info 4

? ? # Debug 5

? ? log_level=4 # 日志級(jí)別

? ? falcon_client=http://127.0.0.1:1988/v1/push # falcon agent連接地址

? ? #自定義endpoint

? ? endpoint=127.0.0.1 #若不設(shè)置則使用OS的hostname

? ? [mysql]

? ? user=root # 數(shù)據(jù)庫(kù)用戶名

? ? password= # 數(shù)據(jù)庫(kù)密碼

? ? host=127.0.0.1 # 數(shù)據(jù)庫(kù)連接地址

? ? port=3306 # 數(shù)據(jù)庫(kù)端口

MySQL metrics

請(qǐng)參考./metrics.txt,其中的內(nèi)容,僅供參考,根據(jù)MySQL的版本、配置不同,采集到的metrics也有差別。

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

友情鏈接更多精彩內(nèi)容