#はじめに
Zabbixにはアプリケーション監視を行うためのアイテムがいくつか用意されていますが、その違いについて纏めてみました。
①プロセス監視
・proc.num[<name>,<user>,<state>,<cmdline>]
<name>に設定した場合は、「ps -e」の結果から存在を検索する事と同等。
<cmd>設定した場合は、「ps -ef」の結果から存在を検索する事と同等。
・service_state[*]
・services[,,]
Windowsのサービスステータスをチェック。
②ポート監視
・net.tcp.listen[port]
・net.udp.listen[port]
「netstat -an」の結果からLISTEN状態であるかどうか評価する事と同等。
・net.tcp.port[<ip>,port]
指定されたポートへTCPレベルでの接続を行う。
「telnet localhost 80」と同様。但し、接続できたことだけで判断。
尚、ここでのIPの指定は外部へアクセスするわけでは無い。
1サーバ内に複数インターフェース(IPアドレス)がある環境でどのインターフェースか指定する場合に使用する。
③サービス接続監視
・net.tcp.service[service,<ip>,<port>]
(service:ssh, ntp, ldap, smtp, ftp, http, pop, nntp, imap, tcp, https, telnet)
・net.tcp.service.perf[service,<ip>,<port>]
(service:ssh, ntp, ldap, smtp, ftp, http, pop, nntp, imap, tcp, https, telnet)
・net.tcp.dns[<ip>,zone]
⇒v2.2~ net.dns[<ip>,zone,<type>,<timeout>,<count>]
・net.tcp.dns.query[<ip>,zone,]
⇒v2.2~ net.dns.record[<ip>,zone,<type>,<timeout>,<count>]
それぞれのプロトコルレベルでの通信を行い、正常性を判断する。
TCP/IPの階層モデルで言うと、net.tcp.portはトランスポート層(レイヤー4)、
net.tcp.service、net.tcp.dnsはアプリケーション層(レイヤー5)でのチェックになる。
④Web監視
・Webシナリオ監視
”監視サーバから”接続確認を行う。
複数ページを横断してアクセスしてチェック出来る。
認証が必要なサイトであっても、標準認証、または標準的なPOPによるチェックであれば認証をパスしてチェックが出来る。
・web.page.get[host,<path>,<port>]
・web.page.perf[host,<path>,<port>]
・web.page.regexp[host,<path>,<port>,<regexp>,<length>,<output>]
Webサイトへの接続チェックを行う。
シナリオ監視は行えないが、エージェントから直接httpサイトへチェックを行うことが出来る。
(DMZ内にあるWebサーバのサイトチェックを行う場合、監視サーバ<=>監視対象サーバ間でhttp(s)ポートを開けなくても良い)