Compare commits
No commits in common. "ad2f04e6a053335aed31fcdb8eb48ab1490c51b5" and "bdb0583395a2873a5571bf83207ae5c127362ef3" have entirely different histories.
ad2f04e6a0
...
bdb0583395
|
@ -12,7 +12,7 @@ services:
|
|||
build:
|
||||
dockerfile: Dockerfile
|
||||
container_name: nagios
|
||||
image: docker-registry1.in.thelinuxpro.net:5000/tlp/nagios:241230.0.1
|
||||
image: docker-registry1.in.thelinuxpro.net:5000/tlp/nagios:241228.0.3
|
||||
networks:
|
||||
infra_dev_net:
|
||||
ipv4_address: 10.99.23.36
|
||||
|
|
|
@ -1,28 +0,0 @@
|
|||
### Hosts
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi501.in.thelinuxpro.net
|
||||
alias pi501
|
||||
address 10.99.22.51
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi502.in.thelinuxpro.net
|
||||
alias pi502
|
||||
address 10.99.22.52
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi503.in.thelinuxpro.net
|
||||
alias pi503
|
||||
address 10.99.22.53
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi504.in.thelinuxpro.net
|
||||
alias pi504
|
||||
address 10.99.22.54
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
### Hosts
|
||||
define host{
|
||||
use web-host
|
||||
host_name kameronkenny.com
|
||||
alias kameronkenny.com
|
||||
address 204.8.15.81
|
||||
}
|
||||
|
||||
define host{
|
||||
use web-host
|
||||
host_name thelinux.pro
|
||||
alias thelinux.pro
|
||||
address 204.8.15.81
|
||||
}
|
|
@ -1,43 +0,0 @@
|
|||
|
||||
### Service definitions for all docker hosts
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description PING
|
||||
check_command check_ping!100.0,20%!500.0,60%
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Docker Daemon
|
||||
check_command check_nrpe!check_proc_docker
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Disk: /
|
||||
check_command check_nrpe!check_disk
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Disk: /var/lib/docker/volumes
|
||||
check_command check_nrpe!check_disk_docker
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Load
|
||||
check_command check_nrpe!check_load
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Total Processes
|
||||
check_command check_nrpe!check_procs
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
### Service definitions for all web hosts
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name web-hosts
|
||||
service_description PING
|
||||
check_command check_ping!100.0,20%!500.0,60%
|
||||
}
|
||||
|
||||
define service{
|
||||
use generic-service,graphed-service
|
||||
hostgroup_name web-hosts
|
||||
service_description HTTPS
|
||||
check_command check_https
|
||||
}
|
|
@ -4,7 +4,7 @@
|
|||
#
|
||||
# NOTES: This config file provides you with some example command definitions
|
||||
# that you can reference in host, service, and contact definitions.
|
||||
#
|
||||
#
|
||||
# You don't need to keep commands in a separate file from your other
|
||||
# object definitions. This has been done just to make things easier to
|
||||
# understand.
|
||||
|
@ -17,7 +17,7 @@
|
|||
# SAMPLE NOTIFICATION COMMANDS
|
||||
#
|
||||
# These are some example notification commands. They may or may not work on
|
||||
# your system without modification. As an example, some systems will require
|
||||
# your system without modification. As an example, some systems will require
|
||||
# you to use "/usr/bin/mailx" instead of "/usr/bin/mail" in the commands below.
|
||||
#
|
||||
################################################################################
|
||||
|
@ -47,7 +47,7 @@ define command{
|
|||
|
||||
|
||||
# This command checks to see if a host is "alive" by pinging it
|
||||
# The check must result in a 100% packet loss or 5 second (5000ms) round trip
|
||||
# The check must result in a 100% packet loss or 5 second (5000ms) round trip
|
||||
# average time to produce a critical error.
|
||||
# Note: Five ICMP echo packets are sent (determined by the '-p 5' argument)
|
||||
|
||||
|
@ -65,7 +65,7 @@ define command{
|
|||
# SAMPLE SERVICE CHECK COMMANDS
|
||||
#
|
||||
# These are some example service check commands. They may or may not work on
|
||||
# your system, as they must be modified for your plugins. See the HTML
|
||||
# your system, as they must be modified for your plugins. See the HTML
|
||||
# documentation on the plugins for examples of how to configure command definitions.
|
||||
#
|
||||
# NOTE: The following 'check_local_...' functions are designed to monitor
|
||||
|
@ -143,14 +143,9 @@ define command{
|
|||
# 'check_http' command definition
|
||||
define command{
|
||||
command_name check_http
|
||||
command_line $USER1$/check_http -I $HOSTADDRESS$ -H $HOSTNAME$
|
||||
command_line $USER1$/check_http -I $HOSTADDRESS$ $ARG1$
|
||||
}
|
||||
|
||||
# 'check_https' command definition
|
||||
define command{
|
||||
command_name check_https
|
||||
command_line $USER1$/check_http -S -I $HOSTADDRESS$ -H $HOSTNAME$
|
||||
}
|
||||
|
||||
# 'check_ssh' command definition
|
||||
define command{
|
||||
|
@ -236,7 +231,7 @@ define command {
|
|||
#
|
||||
# These are sample performance data commands that can be used to send performance
|
||||
# data output to two text files (one for hosts, another for services). If you
|
||||
# plan on simply writing performance data out to a file, consider using the
|
||||
# plan on simply writing performance data out to a file, consider using the
|
||||
# host_perfdata_file and service_perfdata_file options in the main config file.
|
||||
#
|
||||
################################################################################
|
|
@ -1,3 +1,114 @@
|
|||
|
||||
### Host Template
|
||||
define host{
|
||||
name docker-host
|
||||
use generic-host
|
||||
hostgroups docker-hosts
|
||||
check_period 24x7
|
||||
check_interval 5
|
||||
retry_interval 1
|
||||
max_check_attempts 3
|
||||
check_command check-host-alive
|
||||
notification_period 24x7
|
||||
notification_interval 120
|
||||
notification_options d,u,r
|
||||
contact_groups admins
|
||||
register 0
|
||||
}
|
||||
|
||||
### Hosts
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi501.in.thelinuxpro.net
|
||||
alias pi501
|
||||
address 10.99.22.51
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi502.in.thelinuxpro.net
|
||||
alias pi502
|
||||
address 10.99.22.52
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi503.in.thelinuxpro.net
|
||||
alias pi503
|
||||
address 10.99.22.53
|
||||
}
|
||||
|
||||
define host{
|
||||
use docker-host
|
||||
host_name pi504.in.thelinuxpro.net
|
||||
alias pi504
|
||||
address 10.99.22.54
|
||||
}
|
||||
|
||||
### Service definitions for all docker hosts
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description PING
|
||||
check_command check_ping!100.0,20%!500.0,60%
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Docker Daemon
|
||||
check_command check_nrpe!check_proc_docker
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Disk: /
|
||||
check_command check_nrpe!check_disk
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description Disk: /var/lib/docker/volumes
|
||||
check_command check_nrpe!check_disk_docker
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Load
|
||||
check_command check_nrpe!check_load
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Total Processes
|
||||
check_command check_nrpe!check_procs
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Zombie Processes
|
||||
check_command check_nrpe!check_procs
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description System: Logged In users
|
||||
check_command check_nrpe!check_users
|
||||
}
|
||||
|
||||
define service{
|
||||
use local-service,graphed-service
|
||||
hostgroup_name docker-hosts
|
||||
service_description DNS Query: A Record
|
||||
check_command check_dns_a
|
||||
}
|
||||
|
||||
### Service Definitions per docker host
|
||||
define service{
|
||||
use local-service,graphed-service
|
|
@ -4,10 +4,3 @@ define hostgroup{
|
|||
alias Docker Hosts
|
||||
members pi501.in.thelinuxpro.net,pi502.in.thelinuxpro.net,pi503.in.thelinuxpro.net,pi504.in.thelinuxpro.net
|
||||
}
|
||||
|
||||
### Hostgroup
|
||||
define hostgroup{
|
||||
hostgroup_name web-hosts
|
||||
alias web Hosts
|
||||
members kameronkenny.com,thelinux.pro
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
# NOTES: This config file provides you with some example object definition
|
||||
# templates that are refered by other host, service, contact, etc.
|
||||
# definitions in other config files.
|
||||
#
|
||||
#
|
||||
# You don't need to keep these definitions in a separate file from your
|
||||
# other object definitions. This has been done just to make things
|
||||
# easier to understand.
|
||||
|
@ -67,7 +67,7 @@ define host{
|
|||
name linux-server ; The name of this host template
|
||||
use generic-host ; This template inherits other values from the generic-host template
|
||||
check_period 24x7 ; By default, Linux hosts are checked round the clock
|
||||
check_interval 2 ; Actively check the host every 5 minutes
|
||||
check_interval 5 ; Actively check the host every 5 minutes
|
||||
retry_interval 1 ; Schedule host check retries at 1 minute intervals
|
||||
max_check_attempts 10 ; Check each Linux host 10 times (max)
|
||||
check_command check-host-alive ; Default command to check Linux hosts
|
||||
|
@ -80,38 +80,44 @@ define host{
|
|||
register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE!
|
||||
}
|
||||
|
||||
### Host Template
|
||||
define host{
|
||||
name docker-host
|
||||
use generic-host
|
||||
hostgroups docker-hosts
|
||||
check_period 24x7
|
||||
check_interval 3
|
||||
retry_interval 1
|
||||
max_check_attempts 3
|
||||
check_command check-host-alive
|
||||
notification_period 24x7
|
||||
notification_interval 120
|
||||
notification_options d,u,r
|
||||
contact_groups admins
|
||||
register 0
|
||||
}
|
||||
|
||||
|
||||
# Windows host definition template - This is NOT a real host, just a template!
|
||||
|
||||
define host{
|
||||
name web-host
|
||||
use generic-host
|
||||
hostgroups web-hosts
|
||||
check_period 24x7
|
||||
check_interval 2
|
||||
retry_interval 1
|
||||
max_check_attempts 3
|
||||
check_command check-host-alive
|
||||
notification_period 24x7
|
||||
notification_interval 120
|
||||
notification_options d,u,r
|
||||
contact_groups admins
|
||||
register 0
|
||||
}
|
||||
name windows-server ; The name of this host template
|
||||
use generic-host ; Inherit default values from the generic-host template
|
||||
check_period 24x7 ; By default, Windows servers are monitored round the clock
|
||||
check_interval 5 ; Actively check the server every 5 minutes
|
||||
retry_interval 1 ; Schedule host check retries at 1 minute intervals
|
||||
max_check_attempts 10 ; Check each server 10 times (max)
|
||||
check_command check-host-alive ; Default command to check if servers are "alive"
|
||||
notification_period 24x7 ; Send notification out at any time - day or night
|
||||
notification_interval 30 ; Resend notifications every 30 minutes
|
||||
notification_options d,r ; Only send notifications for specific host states
|
||||
contact_groups admins ; Notifications get sent to the admins by default
|
||||
hostgroups windows-servers ; Host groups that Windows servers should be a member of
|
||||
register 0 ; DONT REGISTER THIS - ITS JUST A TEMPLATE
|
||||
}
|
||||
|
||||
|
||||
# We define a generic printer template that can be used for most printers we monitor
|
||||
|
||||
define host{
|
||||
name generic-printer ; The name of this host template
|
||||
use generic-host ; Inherit default values from the generic-host template
|
||||
check_period 24x7 ; By default, printers are monitored round the clock
|
||||
check_interval 5 ; Actively check the printer every 5 minutes
|
||||
retry_interval 1 ; Schedule host check retries at 1 minute intervals
|
||||
max_check_attempts 10 ; Check each printer 10 times (max)
|
||||
check_command check-host-alive ; Default command to check if printers are "alive"
|
||||
notification_period workhours ; Printers are only used during the workday
|
||||
notification_interval 30 ; Resend notifications every 30 minutes
|
||||
notification_options d,r ; Only send notifications for specific host states
|
||||
contact_groups admins ; Notifications get sent to the admins by default
|
||||
register 0 ; DONT REGISTER THIS - ITS JUST A TEMPLATE
|
||||
}
|
||||
|
||||
|
||||
# Define a template for switches that we can reuse
|
||||
define host{
|
||||
|
@ -158,8 +164,8 @@ define service{
|
|||
is_volatile 0 ; The service is not volatile
|
||||
check_period 24x7 ; The service can be checked at any time of the day
|
||||
max_check_attempts 3 ; Re-check the service up to 3 times in order to determine its final (hard) state
|
||||
check_interval 2 ; Check the service every 10 minutes under normal conditions
|
||||
retry_interval 1 ; Re-check the service every two minutes until a hard state can be determined
|
||||
check_interval 10 ; Check the service every 10 minutes under normal conditions
|
||||
retry_interval 2 ; Re-check the service every two minutes until a hard state can be determined
|
||||
contact_groups admins ; Notifications get sent out to everyone in the 'admins' group
|
||||
notification_options w,u,c,r ; Send notifications about warning, unknown, critical, and recovery events
|
||||
notification_interval 60 ; Re-notify about service problems every hour
|
Loading…
Reference in New Issue