Version 2 (modified by jonmills, 8 years ago)

--

Overview

Once you install OMD and create a site, you'll have an install homedir, $OMD_ROOT, which will look like /omd/sites/sitename (whatever you set your 'sitename' to be). Relative to that base, all of the configuration files used by Check_MK are found in ~/etc/check_mk. You don't need to worry about configuring Nagios itself, because that's the point of running Check_MK. It dynamically rebuilds your Nagios object configuration for you.

Use the tarball attached to this page to get an idea of a basic Check_MK configuration suitable for monitoring a Eucalyptus cluster. (Note that you'll need to change hostnames found in hosts.mk to suit your environment).

All of the files described here are completely arbitrary, and were just the logical layout preferred by this author. If you pleased, you could group all Check_MK declarations into one big main.mk file (just as you can write all Nagios object configuration into one big nagios.cfg -- but who does that?).

main.mk

I try to define global things here, like:

define_hostgroups = True
define_servicegroups = True
define_contactgroups = True
nagios_illegal_chars = '`~!$%^&*|\'"<>?,()='
generate_hostconf = True
perfdata_format = "pnp"
tcp_connect_timeout = 25.0
inventory_max_cachefile_age = 120 # seconds (Default: 120 seconds)
inventory_check_interval = 3 # minutes
inventory_check_severity = 1
always_cleanup_autochecks = True

Note that setting the 'inventory_check_interval' means that Check_MK will use the check_mk_agent to run a regularly scheduled inventory of the host that it's monitoring. So it can tell you when it's not monitoring everything that it could be monitoring. Setting 'inventory_check_severity' to 1 means that when the service 'Check_MK inventory' discovers a check it knows about, but which it isn't monitoring, it goes into WARNING status (recall that in Nagios lingo, OK is an exit status 0, WARNING is 1, CRITICAL is 2, and UNKNOWN is 3).

active.mk

Used for writing traditional active checks into your Nagios configuration.

checks.mk

contacts.mk

eventhandlers.mk

hostgroups.mk

hosts.mk

ignore.mk

ipaddresses.mk

servicegroups.mk

Attachments