設定ファイル一覧

nrpe

nrpe-server(監視したいリモートホスト)

インストール

sudo apt-get install nagios-nrpe-server nagios-plugins

設定

dont_blame_nrpe

デフォルトだと nrpe に引数付きチェックを実行させる事はできないが、
dont_blame_nrpe=1 で引数付きのリクエストを受け付けてくれる。

# /etc/nagios/nrpe.cfg
dont_blame_nrpe=1

nrpe-server restart 後、nagios 側で下記のような -a 付きのコマンドを実行できるようになる。

/usr/lib/nagios/plugins/check_nrpe -H hostname -c check_foo -a bar

nagios

インストール

sudo apt-get install nagios-nrpe-plugin

設定

service 定義
# /etc/nagios2/conf.d/services_nagios2.cfg
define service{
        use                             generic-service         ; Name of service template to use
        host_name                       hostname
        service_description             nrpe disk
        is_volatile                     0
        check_period                    24x7
        max_check_attempts              5
        normal_check_interval           30
        retry_check_interval            1
        contact_groups                  admins
        notification_interval           120
        notification_period             24x7
        notification_options            c,r
        check_command                   check_nrpe_1arg!check_disk1
        }

よく使う plugin

check_disk

check_dns

check_fileage

check_http

check_icmp

check_log

check_load

check_mailq

check_mysql

check_mysql_query

check_nagios

check_ntp

check_pop

check_smtp

check_swap

check_tcp

check_udp

nagios.txt · Last modified: 2007/09/15 18:35 by topaz2