Решил освоить данную систему мониторинга.
Установил, но возникло пару проблем:
1. Не работает snmp.
2. Не работает почтовые уведомления.
1. Поставил snmp и snmpd.
У меня большие подозрения, что не до конца настроил. Перечитал кучу всякой вспомогательной информации, настраивал и так - и сяк, но работать не хочет.
Что имеем:
# cat /etc/snmp/snmpd.conf
rocommunity public
# cat /etc/default/snmpd
# This file controls the activity of snmpd and snmptrapd
# Don't load any MIBs by default.
# You might comment this lines once you have the MIBs downloaded.
export MIBS=
# snmpd control (yes means start daemon).
SNMPDRUN=yes
# snmpd options (use syslog, close stdin/out/err).
#SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid'
SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -I -smux -p /var/run/snmpd.pid -c /etc/snmp/snmpd.conf'
# snmptrapd control (yes means start daemon). As of net-snmp version
# 5.0, master agentx support must be enabled in snmpd before snmptrapd
# can be run. See snmpd.conf(5) for how to do this.
TRAPDRUN=no
# snmptrapd options (use syslog).
TRAPDOPTS='-Lsd -p /var/run/snmptrapd.pid'
# create symlink on Debian legacy location to official RFC path
SNMPDCOMPAT=yes
# cat cisco_test.cfg
define hostgroup{
hostgroup_name Cisco
alias Cisco test
}
# 'Cisco' host definition
define host{
use generic-switch
host_name cisco
alias cisco test
address x.x.x.x
hostgroups Cisco
}
# Create a service to PING to switch
#Cisco
define service{
use generic-service
host_name cisco
service_description PING
check_command check_ping!200.0,20%!600.0,60%
normal_check_interval 5
retry_check_interval 1
}
#Temperature
define service{
use cis
host_name cisco
service_description Temperature
check_command check_snmp!-o 1.3.6.1.4.1.9.9.13.1.3.1.6.1 -C public -w 60 -c 75 -u
}
# cat templates.cfg
......
.....
.....
define service{
name cis
active_checks_enabled 1
passive_checks_enabled 1
parallelize_check 1
obsess_over_service 1
check_freshness 0
notifications_enabled 1
event_handler_enabled 1
flap_detection_enabled 1
failure_prediction_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
is_volatile 0
check_period 24x7
max_check_attempts 3
normal_check_interval 15
retry_check_interval 1
contact_groups admins
notification_options w,c,r
notification_interval 120
notification_period 24x7
register 0
}
В web-интерфейсе Nagios:
PING OK 03-31-2011 12:59:19 0d 0h 5m 13s 1/3 PING OK - Packet loss = 0%, RTA = 2.66 ms
Temperature UNKNOWN 03-31-2011 12:50:40 8d 19h 14m 41s 3/3 Usage: OID верный. Он же используется для этой же железки другой системой мониторинга (Cricket).
Если нужна какая-то доп. информация, чтобы помочь мне, то напишите, я выложу.
2. Поставил mailx и exim4.
Подозреваю, что их тоже настроил не до конца. Хотя делал все по мануалам.
define contact{
contact_name nagiosadmin ; Short name of user
use generic-contact ; Inherit default values from generic-contact template (defined above)
alias Nagios Admin ; Full name of user
host_notifications_enabled 1
service_notifications_enabled 1
service_notification_period 24x7
host_notification_period 24x7
service_notification_options w,u,c,r
host_notification_options d,u,r
email xxxxxx@mail.ru ; <<***** CHANGE THIS TO YOUR EMAIL ADDRESS ******
can_submit_commands 1
}
# cat /var/log/exim4/paniclog
2011-03-31 12:25:57 socket bind() to port 25 for address ::1 failed: Cannot assign requested address: daemon abandoned
Как настраивать exim4 до конца так и не понял. Что-то делал неделю назад, но уже сейчас не вспомню в каких конфигурационных файлах.
Если напишите, из каких нужны данные сюда выложить, то соответственно напишу сюда что там.
Просьба помочь

Пользователь решил продолжить мысль 31 Марта 2011, 14:33:48:
snmptt нужно дополнительно устанавливать и настраивать или не?