diff options
Diffstat (limited to 'README')
-rw-r--r-- | README | 95 |
1 files changed, 38 insertions, 57 deletions
@@ -31,11 +31,11 @@ Hosts ----- On a node which shall be monitored with nagios, include the "nagios::target". -This just creates a host declaration for this host's "$ipaddress" fact. If -the $ipaddress of your target is not the one you wish to modify, you can use -"nagios::target::fqdn" instead, which will use the $fqdn fact of the host instead. +This just creates a host declaration for this host's "$::ipaddress" fact. If +the $::ipaddress of your target is not the one you wish to modify, you can use +"nagios::target::fqdn" instead, which will use the $::fqdn fact of the host instead. -Set the $nagios_parents variable in the node scope for enabling the reachability +Pass the $parents variable to the target class for enabling the reachability features of nagios. If a node needs more customisation, use the native "@@nagios_host" type directly (the double-ampersand declares the object as an exported resource). @@ -95,14 +95,14 @@ Upgrade Notes The nagios::target bits have been reworked, the notable changes that may affect an upgrade are: -. previous versions had nagios::target::nat which used the $fqdn for +. previous versions had nagios::target::nat which used the $::fqdn for the address part of nagios::target, this has been renamed to nagios::target::fqdn to be more clear. if you were using nagios::target::nat then you will need to change those references to ::fqdn -. previous versions of this module used $fqdn for the nagios::target -address, now it is using $ipaddress. If you need $fqdn, use +. previous versions of this module used $::fqdn for the nagios::target +address, now it is using $::ipaddress. If you need $::fqdn, use nagios::target::fqdn instead of nagios::target . previous versions of nagios_host used the parameter named 'ip', that @@ -155,63 +155,43 @@ See : http://projects.reductivelabs.com/issues/1180 Variables ========= -Options to change the behavior of the nagios module: +Options to change the behavior of the nagios class: -- nagios_parents: Which host(s) are this node's parents in the nagios host map. +- allow_external_cmd: Set to true, if you'd like to ensure that your http + daemon can write to the external command file. You + may also need to flip "check_external_commands" in + "nagios.cfg" to enable this functionality. -- nagios_allow_external_cmd: Set to true, if you'd like to ensure that your http - daemon can write to the external command file. You - may also need to flip "check_external_commands" in - "nagios.cfg" to enable this functionality. +For the irc_bot class: -- nagios_cfgdir: specify an alternative directory where Nagios configurations - should be managed. Default value depends of the OS of each - node, but is usually something like '/etc/nagios3'. +- nsa_socket: This optional variable can be used to specify the path to + the socket file that the IRC daemon should use. -- nagios_plugin_dir: Change the directory where Nagios plugins should be - deployed and pointed to by commands. +- nsa_server: When using the IRC bot, this defines the server address of + the IRC network on which the bot will connect. -- nagios_nrpe_cfgdir: Change the directory where NRPE configurations should be - managed. The default value depends on the node's OS but - is usually something like '/etc/nagios'. +- nsa_port: Defines the port number on the IRC server on which the bot + should connect. When this variable is not set, the port used + by default is 6667. -- nagios_nrpe_pid_file: Change where the PID file for the Nagios service should - be written to. It's usually a good idea to keep this - file where the init script will find it so that it can - verify the service's status. +- nsa_nickname: This is the nickname that the IRC bot will take. -- nagios_nrpe_dont_blame: Set this to 1 to allow arguments to be passed along - with NRPE command calls. Set it to 0 to disable - command arguments. +- nsa_password: Some networks require a password to connect to them. + This defines such a password. -- nagios_nsa_socket: This optional variable can be used to specify the path to - the socket file that the IRC daemon should use. +- nsa_channel: The name of the channel that the IRC bot will join and + will post notifications to. -- nagios_nsa_server: When using the IRC bot, this defines the server address of - the IRC network on which the bot will connect. +- nsa_pidfile: This optional variable can be used to define the path to + the file that will contain the process ID of the IRC bot + daemon. +- nsa_realname: The IRC bot user's real name that will be displayed. By + default, the real name is 'Nagios'. -- nagios_nsa_port: Defines the port number on the IRC server on which the bot - should connect. When this variable is not set, the port used - by default is 6667. - -- nagios_nsa_nickname: This is the nickname that the IRC bot will take. - -- nagios_nsa_password: Some networks require a password to connect to them. - This defines such a password. - -- nagios_nsa_channel: The name of the channel that the IRC bot will join and - will post notifications to. - -- nagios_nsa_pidfile: This optional variable can be used to define the path to - the file that will contain the process ID of the IRC bot - daemon. -- nagios_nsa_realname: The IRC bot user's real name that will be displayed. By - default, the real name is 'Nagios'. - -- nagios_nsa_usenotices: The IRC bot will by default "say" to the channel the - nagios message, but you can switch this variable to - 'notice' if you would prefer them to be sent as IRC - NOTICE messages. +- nsa_usenotices: The IRC bot will by default "say" to the channel the + nagios message, but you can switch this variable to + 'notice' if you would prefer them to be sent as IRC + NOTICE messages. Examples ======== @@ -247,9 +227,10 @@ $HOSTADDRESS$' node target { - # Monitor th () is host - $nagios_parents = 'router01' - include nagios::target + # Monitor this host + class{'nagios::target': + parents = 'router01' + } # monitor a service $apache2_port = 8080 |