LoginSignup
0
0

More than 5 years have passed since last update.

Muninで外部サーバーを監視した際の備忘録

Last updated at Posted at 2016-09-04

中途半端な調べ方をして無駄に詰まってしまってたので、備忘録として。

環境

監視元サーバー(VirtualBox)

OS
$ cat /etc/redhat-release 
CentOS Linux release 7.2.1511 (Core) 

apache
$ httpd -v
Server version: Apache/2.4.6 (CentOS)
Server built:   Jul 18 2016 15:30:14

監視先サーバー(VPS)

OS
$ cat /etc/redhat-release                                                             
CentOS Linux release 7.2.1511 (Core) 

nginx
$ nginx -v
nginx version: nginx/1.11.3

php-fpm
$ php-fpm -v                                                                          
PHP 7.0.9 (fpm-fcgi) (built: Jul 20 2016 17:59:09)

mariaDB
$ mysql --version                                                                     
mysql  Ver 15.1 Distrib 10.1.17-MariaDB, for Linux (x86_64) using readline 5.1

手順

・まずは下記参考サイトを参考に監視元サーバーのみで検証を行い、データが取得できるか試す。
http://www.server-memo.net/server-setting/munin/munin-install.html

・ここを参考に監視元サーバーのApacheとMySQL(MariaDB)の項目を追加してみたりするテスト。
http://d.hatena.ne.jp/yk5656/20140529/1402822603

・監視先サーバー追加まわりの設定を行う。
http://tech.basicinc.jp/munin/2013/08/11/munin_nginx_php-fpm/

・ポート開放はfirewalldのサービスにmunin-nodeを追加でOK。
munin-nodeインストール時にserviceとして追加されているはず。

$ sudo firewall-cmd --zone=public --add-service=munin-node --permanent
$ sudo firewall-cmd --reload

・グラフをクリックしまくって最大画面にした際、グラフが表示されなくなる不具合に遭遇すると思うので、下記サイトを参考に対処する。
http://d.hatena.ne.jp/pospome/20130221/1361447896

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0