Servidor de monitoramento Nagios
Imagine poder monitorar todos seus servidores, clientes, impressoras, roteadores e switches em um único servidor e serviço. Receber relatórios por e-mail, celular, bem como saber quantas vezes um servidor ficou fora do ar e voltou a funcionar.
Parte 4: Arquivo printer.cfg
Neste arquivo você configura para monitorar uma impressora de rede, a sintaxe é idêntica ao arquivo anterior, com suas devidas seções.
# HOST DEFINITIONS - Definição de host, ip, grupo
# Define a host for the printer we'll be monitoring
define host{
use generic-printer ; Inherit default values from a template
host_name Canon iPR Server T1 Ver1.0 ; The name we're giving to this printer
alias Canon iPR Server T1 Ver1.0(BOTAFOGO) ; A longer name associated with the printer
address 192.168.80.50 ; IP address of the printer
hostgroups network-printers ; Host groups this printer is associated with
}
# HOST GROUP DEFINITIONS - Definição do grupo, nomes.
# A hostgroup for network printers
define hostgroup{
hostgroup_name network-printers ; The name of the hostgroup
alias Impressoras REDE ; Long name of the group
}
# SERVICE DEFINITIONS - Define os serviços a serem checados
define service{
use generic-service
host_name Canon iPR Server T1 Ver1.0
service_description PING
check_command check_ping!3000.0,80%!5000.0,100%
normal_check_interval 10
retry_check_interval 1
}
# Define a host for the printer we'll be monitoring
define host{
use generic-printer ; Inherit default values from a template
host_name Canon iPR Server T1 Ver1.0 ; The name we're giving to this printer
alias Canon iPR Server T1 Ver1.0(BOTAFOGO) ; A longer name associated with the printer
address 192.168.80.50 ; IP address of the printer
hostgroups network-printers ; Host groups this printer is associated with
}
# HOST GROUP DEFINITIONS - Definição do grupo, nomes.
# A hostgroup for network printers
define hostgroup{
hostgroup_name network-printers ; The name of the hostgroup
alias Impressoras REDE ; Long name of the group
}
# SERVICE DEFINITIONS - Define os serviços a serem checados
define service{
use generic-service
host_name Canon iPR Server T1 Ver1.0
service_description PING
check_command check_ping!3000.0,80%!5000.0,100%
normal_check_interval 10
retry_check_interval 1
}
Parabéns!!!