Linuxへmackerelのサービス監視用の設定手順
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
[[mackerel]]
*事前準備 [#pd802977]
# yum install mackerel-agent-plugins
まとめてプラグインをインストール
*apache [#eb89222f]
# cd /etc/httpd/conf/
# cp -p httpd.conf httpd.conf.`date +%Y%m%d`
# vi httpd.conf
--- 下記追記
Listen 1080
ExtendedStatus On
<VirtualHost 127.0.0.1:1080>
<Location /server-status>
SetHandler server-status
</Location>
</VirtualHost>
---
# service httpd configtest
# service httpd graceful
# cd /etc/mackerel-agent/
# cp -p mackerel-agent.conf mackerel-agent.conf.`date +%...
# vi mackerel-agent.conf
--- 下記コメントアウトをアンコメントしてtypeとポートを指定
[plugin.metrics.apache2]
command = "/usr/local/bin/mackerel-plugin-apache2 -p 1080"
type = "metric"
---
# /etc/init.d/mackerel-agent restart
# /usr/local/bin/mackerel-plugin-apache2 -p 1080 <--確認
*MySQL [#y7ebfded]
---MySQLでmackerel用のユーザーを追加
mysql> grant all privileges on *.* to mackerel@localhost...
mysql> flush privileges;
# cd /etc/mackerel-agent/
# cp -p mackerel-agent.conf mackerel-agent.conf.`date +%...
# vi mackerel-agent.conf
--- 下記をアンコメントして、ユーザー名とパスワードを追記...
[plugin.metrics.mysql]
command = "/usr/local/bin/mackerel-plugin-mysql -usernam...
type="metric"
---
# /etc/init.d/mackerel-agent restart
~
以上でmackerelのダッシュボード上に、customのロールが増え...
参考URL:http://youngforever.hatenablog.com/entry/2015/02...
終了行:
[[mackerel]]
*事前準備 [#pd802977]
# yum install mackerel-agent-plugins
まとめてプラグインをインストール
*apache [#eb89222f]
# cd /etc/httpd/conf/
# cp -p httpd.conf httpd.conf.`date +%Y%m%d`
# vi httpd.conf
--- 下記追記
Listen 1080
ExtendedStatus On
<VirtualHost 127.0.0.1:1080>
<Location /server-status>
SetHandler server-status
</Location>
</VirtualHost>
---
# service httpd configtest
# service httpd graceful
# cd /etc/mackerel-agent/
# cp -p mackerel-agent.conf mackerel-agent.conf.`date +%...
# vi mackerel-agent.conf
--- 下記コメントアウトをアンコメントしてtypeとポートを指定
[plugin.metrics.apache2]
command = "/usr/local/bin/mackerel-plugin-apache2 -p 1080"
type = "metric"
---
# /etc/init.d/mackerel-agent restart
# /usr/local/bin/mackerel-plugin-apache2 -p 1080 <--確認
*MySQL [#y7ebfded]
---MySQLでmackerel用のユーザーを追加
mysql> grant all privileges on *.* to mackerel@localhost...
mysql> flush privileges;
# cd /etc/mackerel-agent/
# cp -p mackerel-agent.conf mackerel-agent.conf.`date +%...
# vi mackerel-agent.conf
--- 下記をアンコメントして、ユーザー名とパスワードを追記...
[plugin.metrics.mysql]
command = "/usr/local/bin/mackerel-plugin-mysql -usernam...
type="metric"
---
# /etc/init.d/mackerel-agent restart
~
以上でmackerelのダッシュボード上に、customのロールが増え...
参考URL:http://youngforever.hatenablog.com/entry/2015/02...
ページ名: