顯示具有 nagios 標籤的文章。 顯示所有文章
顯示具有 nagios 標籤的文章。 顯示所有文章

2014年12月29日 星期一

FAN - Fully Automated Nagios

比較 :
OMD - Open Monitoring Distribution
Integrated tools :
  • Nagios : core monitoring application;
  • Nagios plug-ins : plug-ins to monitor different equipments;
  • Centreon : Web interface for Nagios (Centreon is one of the best for this purpose!);
  • NagVis : advanced mapping (geographical, functional, by services…);
  • NDOUtils : stores the Nagios data into a MySQL database;
  • NRPE : makes it possible to monitor the Windows servers (the NRPE daemon is not provided);
  • NaReTo (Nagios Reporting Tools): reporting tool (availability report).





FAN « Fully Automated Nagios

OMD - Open Monitoring Distribution

比較 :
FAN - Fully Automated Nagios

OMD 包含軟體 :
  • Nagios
  • Icinga
  • Shinken
  • NagVis
  • rrdtool/rrdcached
  • Check_MK
  • MK Livestatus
  • Multisite
  • Thruk
  • Mod-Gearman
  • check_logfiles
  • check_oracle_health
  • check_mysql_health
  • jmx4perl
  • check_webinject
  • check_multi

改進功能:
Livestatus and Livecheck

OMD Architecture :



References :
Open Monitoring Distribution
The Check_MK Monitoring System
Best Monitoring Solution - OMD (Nagios + Check_MK) | IT on Demand

Thruk

功能:
Multibackend monitoring webinterface

支援監控軟體:
Naemon, Nagios, Icinga, Shinken

Backend 協定:
Livestatus API




References :
Thruk Monitoring Webinterface

Nagios NagVis

功能:
使用地圖、拓撲圖、機櫃圖等背景照片顯示 Nagios 監控的主機狀態

支援的 Backends 協定:
mklivestatus, ndomy, ndo2fs, merlinmy

設定檔位置:
/etc/nagvis/nagvis.ini.php




References :
Backends
Use Shinken with Nagvis — Shinken Manual 2.2-RC1 documentation
[转]安装使用Nagvis插件 - OneCMDB中文

2013年12月28日 星期六

Nagios notify by gmail

# cd /usr/lib/nagios/plugins
# wget  http://exchange.nagios.org/components/com_mtree/attachment.php?link_id=3489&cf_id=24 -O  send_gmail.py
# vi send_gmail.py
# change to your username and password
# vi /etc/nagios3/conf.d/contacts_nagios2.cfg
define contact{
        contact_name                    root
        alias                           Root
        service_notification_period     24x7
        host_notification_period        24x7
        service_notification_options    w,u,c,r
        host_notification_options       d,r
        service_notification_commands   notify-service-by-email
        host_notification_commands      notify-host-by-email
       email                           YOUR_EMAIL_ADDRESS
# vi /etc/nagios3/commands.cfg
# comment old 'notify-host-by-email' and 'notify-service-by-email' command line and add follows
# *)notify-host-by-email

command_line /usr/bin/python /usr/lib/nagios/plugins/send_gmail.py -a $CONTACTEMAIL$ -b "***** Nagios *****\nnn\nnnNotification Type: $NOTIFICATIONTYPE$\nnnHost: $HOSTNAME$\nnnState: $HOSTSTATE$\nnnAddress: $HOSTADDRESS$\nnnInfo: $HOSTOUTPUT$\nnnDate/Time: $LONGDATETIME$" -s "** Nagios $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$ **"

#notify-service-by-email

command_line /usr/bin/python /usr/lib/nagios/plugins/send_gmail.py -a $CONTACTEMAIL$ -b "***** Nagios *****\nnn\nnnNotification Type: $NOTIFICATIONTYPE$\nnnService: $SERVICEDESC$\nnnHost: $HOSTALIAS$\nnnAddress: $HOSTADDRESS$\nnnState: $SERVICESTATE$\nnnDate/Time: $LONGDATETIME$\nnnAdditional Info: $SERVICEOUTPUT$" -s "** Nagios $NOTIFICATIONTYPE$ Service Alert: $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" 



References :
Nagios Alerts via gmail and python - Nagios Exchange
4 Steps to Define Nagios Contacts With Email and Pager Notification

2013年11月13日 星期三

Nagios check_http on different port

/usr/lib/nagios/plugins/check_http


check_command   check_http!-p 8080
if with ssl support :
check_command           check_http! -ssl




Reference :
Jon Witts' Blog » Nagios check_http plugin

Nagios plugin 測試

check 程式 :
# ls /usr/lib/nagios/plugins/
參數設定檔 :

# ls /usr/share/nagios-plugins/


# /usr/lib/nagios/plugins/check_mysql -H localhost -u root  -p your_password -d mysql




Reference :
資訊隨筆 - 利用 Nagios 來偵測網路服務

nagios使用check_mysql监控mysql - 潜入技术的海洋 - 51CTO技术博客

Sorry, but Nagios is currently not checking for external commands, so your command will not be committed!

Sorry, but Nagios is currently not checking for external commands, so your command will not be committed!

# vi /etc/nagios3/nagios.cfg
check_external_command=1

# /etc/init.d/nagios3 restart




Reference :
Fix to Nagios is currently not checking for external commands | Walking in Light with Christ - Faith, Computing, Diary

2013年11月12日 星期二

Debian 安裝 Nagios3

安裝 Web Server 與 Database :
# apt-get install apache2 libapache2-mod-php5 mysql-server
安裝 Nagios Server :
# apt-get install nagios3 nagios-plugins ndoutils-nagios3-mysql nagios-nrpe-plugin
安裝完會在 Apache 設定檔資料夾裏產生 nagios 的設定檔連結
# ls -l /etc/apache2/conf.d/nagios3.conf
/etc/apache2/conf.d/nagios3.conf -> /etc/nagios3/apache2.conf
重新啓動 Apache
# /etc/init.d/apache2 restart


Configuration :

可設定羣組,以分類主機 (by OS, Service, ...)
# vi /etc/nagios3/conf.d/hostgroups_nagios2.cfg

設定警報通知聯絡人
# vi /etc/nagios3/conf.d/contacts_nagios2.cfg   

設定監視的主機
# vi /etc/nagios3/conf.d/generic-host_nagios2.cfg

設定主機監視的服務(by /etc/nagios3/conf.d/commands.cfg or nagios-plugins (check_http, check_ssh)或執行系統狀態檢查指令 (with nagios-nrpe-plugin)
# vi /etc/nagios3/conf.d/generic-service_nagios2.cfg 


* nagios-plugins :
# ls /usr/share/nagios-plugins/
# ls /usr/lib/nagios/plugins/

* NRPE - Nagios Remote Plugin Executor




Reference :
Setting up Nagios on Debian or Ubuntu » cloud101
Monitoring Publicly Available Services

利用插件扩展Nagios的监控功能_风信网

Install Nagios 3.5.0 manually on Debian 7.0 | IT Secure NetIT Secure Net