Home | 簡體中文 | 繁體中文 | 雜文 | 知乎專欄 | Github | OSChina 博客 | 雲社區 | 雲棲社區 | Facebook | Linkedin | 視頻教程 | 打賞(Donations) | About
知乎專欄多維度架構 微信號 netkiller-ebook | QQ群:128659835 請註明“讀者”

第 100 章 Munin

目錄

100.1. Ubuntu
100.1.1. Installation Monitor Server
100.1.2. Installation Node
100.1.3. Additional Plugins
100.1.4. plugins
100.1.4.1. mysql
100.1.4.2. apache
100.2. CentOS
100.3. 用戶認證
100.4. munin-node and plugins
100.4.1. munin-node.conf
100.4.2. mysql plugin
100.4.3. apache plugin
100.4.4. memcached plugin
100.5. munin.conf
100.6. munin-node
100.6.1. munin-node.conf

http://munin-monitoring.org/

100.1. Ubuntu

http://munin-monitoring.org/

100.1.1. Installation Monitor Server

$ sudo apt-get install munin

neo@monitor:~$ sudo vim /etc/munin/munin.conf
neo@monitor:~$ sudo service munin-node restart


[example.com]
        address 127.0.0.1
        use_node_name yes
        
[web2]
    address 172.16.1.2
    use_node_name yes

[web3]
    address 172.16.1.3
    use_node_name yes

[database]
    address 172.16.1.10
    use_node_name yes

		

100.1.2. Installation Node

sudo apt-get install munin-node

vim /etc/munin/munin-node.conf

allow ^172\.16\.1\.2$
		

100.1.3. Additional Plugins

sudo apt-get install munin-plugins-extra
		

100.1.4. plugins

100.1.4.1. mysql
ln -s /usr/share/munin/plugins/mysql_* /etc/munin/plugins/
			

/etc/munin/plugin-conf.d/munin-node

$ sudo vim /etc/munin/plugin-conf.d/munin-node

[mysql*]
user root
env.mysqlopts --defaults-file=/etc/mysql/debian.cnf
env.mysqluser debian-sys-maint
env.mysqlconnection DBI:mysql:mysql;mysql_read_default_file=/etc/mysql/debian.cnf

[mysql*]
env.mysqlopts -h 192.168.3.40 -uneo -pchen
			
100.1.4.2. apache
$ sudo vim /etc/munin/plugin-conf.d/munin-node
			
[apache_*]
env.url   http://127.0.0.1/server-status?auto
env.ports 80