Share

GroundWork Monitor Architect

Tracker: Feature Requests

5 Nagios Main Configuration - ID: 1601028
Last Update: Comment added ( offsides )

To use the ndoutils i need a field where i can edit the broker_module and
the event_broker_options.

Or you can add an custom field where users can add his own additional text.


evoforce ( evoforce ) - 2006-11-22 09:59

5

Closed

None

Nobody/Anonymous

None

None

Public


Comments ( 4 )




Date: 2007-01-09 18:27
Sender: offsides


OK, my bad - I didn't see the little bit at the bottom of the last page
for misc directives. It works.


Date: 2007-01-09 17:00
Sender: offsides


As of Monarch 2.0.2 this patch is not implemented, nor is there any way to
implement a custom field in the main nagios config. Monarch 2.0.2
downloaded approximately an hour ago...


Date: 2007-01-09 01:59
Sender: itgroundworkProject Admin


custom fields implemented in 2.0


Date: 2006-11-22 18:40
Sender: offsides


I just did this a couple days ago, and posted it to the GroundWork Forums
- here's what I did (and it does work):

--- monarch.cgi.orig.1.3 2006-10-27 07:34:26.000000000 -0400
+++ /var/www/cgi-bin/monarch.cgi 2006-11-15 13:38:30.000000000
-0500
@@ -8256,6 +8256,8 @@
$page .= Forms->text_box('Illegal macro
output
characters:','illegal_macro_output_chars',$objects{'illegal_macro_output_chars'}[2],$textsize{'long_name'},'',$docs{'illegal_macro_output_chars'});
$page .= Forms->text_box('Admin
email:','admin_email',$objects{'admin_email'}[2],$textsize{'long_name'},'',$docs{'admin_email'});
$page .= Forms->text_box('Admin
pager:','admin_pager',$objects{'admin_pager'}[2],$textsize{'long_name'},'',$docs{'admin_pager'});
+ $page .= Forms->text_box('Event broker
options:','event_broker_options',$objects{'event_broker_options'}[2],$textsize{'small'},'',$docs{'event_broker_options'});
+ $page .= Forms->text_box('Broker
module:','broker_module',$objects{'broker_module'}[2],$textsize{'long_name'},'',$docs{'broker_module'});
$page .= Forms->hidden(\%hidden);
%save = ('name' => 'next', 'value' =>
'Save and Done');
$page .=
Forms->form_bottem_two_button(\%back,\%save,$tab++);
--- MonarchDoc.pm.orig.1.3 2006-11-15 13:42:38.000000000 -0500
+++ MonarchDoc.pm 2006-11-15 13:42:19.000000000 -0500
@@ -564,6 +564,8 @@
$docs{'illegal_macro_output_chars'} = q(Illegal macro output
chars: This option allows you to specifyillegal characters that are
stripped from macros before being used in notifications, event handlers,
etc. This DOES NOT affect macros used in service or host check commands.
The following macros are stripped of the characters you specify: $OUTPUT$,
$PERFDATA$.);
$docs{'admin_email'} = q(Admin email: The email address of the
administrator of *this* machine (the one doing the monitoring). Nagios
never uses this value itself, but you can access this value by using the
$ADMINEMAIL$ macro in your notification commands.);
$docs{'admin_pager'} = q(Admin pager: The pager number/address for
the administrator of *this* machine. Nagios never uses this value itself,
but you can access this value by using the $ADMINPAGER$ macro in your
notification commands.);
+ $docs{'event_broker_options'} = q(Event broker options: Set this
value to 0 to turn off the event broker, or -1 to send all events through
the event broker. All other values are a bitwise mask for the various
(currently undocumented) event broker options.);
+ $docs{'broker_module'} = q(Broker module: this is the full path of
the event broker module to use, aswell as any parameters to be issued to
the broker module.);
# 2.0
$docs{'object_cache_file_file'} = q(Object cache file: This
directive is used to specify a file in which a cached copy of object
definitions should be stored. The cache file is (re)created every time
Nagios is (re)started and is used by the CGIs. It is intended to speed up
config file caching in the CGIs and allow you to edit the source object
config files while Nagios is running without affecting the output displayed
in the CGIs.);
$docs{'execute_host_checks'} = q(Host check execution option: This
option determines whether or not Nagios will execute on-demand and
regularly scheduled host checks when it initially (re)starts. If this
option is disabled, Nagios will not actively execute any host checks,
although it can still accept passive host checks unless you've disabled
them. This option is most often used when configuring backup monitoring
servers, as described in the documentation on redundancy, or when setting
up a distributed monitoring environment. Note: Ifyou have state retention
enabled, Nagios will ignore this setting when it (re)starts and use the
last known setting for this option (as stored in the state retention file),
unless you disable the use_retained_program_state option. If you want to
change this option when state retention is active (and the
use_retained_program_state is enabled), you'll have to use the appropriate
external command or change it via the web interface. Checked = Execute host
checks.);
--- MonarchFile.pm.orig.1.3 2006-10-27 07:34:26.000000000 -0400
+++ MonarchFile.pm 2006-11-15 13:44:58.000000000 -0500
@@ -98,7 +98,7 @@

'service_perfdata_file_template','host_perfdata_file_mode','service_perfdata_file_mode','host_perfdata_file_processing_interval',

'service_perfdata_file_processing_interval','host_perfdata_file_processing_command','service_perfdata_file_processing_command',

'check_for_orphaned_services','check_service_freshness','freshness_check_interval','check_host_freshness','host_freshness_check_interval',
-'date_format','illegal_object_name_chars','illegal_macro_output_chars','admin_email','admin_pager');
+'date_format','illegal_object_name_chars','illegal_macro_output_chars','admin_email','admin_pager','event_broker_options','broker_module');

my $sqlstmt = "select file_id, name, path from files where file_id
in (select distinct file_id from file_host)";
my $sth = $dbh->prepare ($sqlstmt);
--- MonarchStorProc.pm.orig.1.3 2006-10-27 07:34:26.000000000 -0400
+++ MonarchStorProc.pm 2006-11-15 14:06:11.000000000 -0500
@@ -3180,6 +3180,8 @@
$nagios{'illegal_macro_output_chars'} = q(`~$&|'"<>);
$nagios{'admin_email'} = 'nagios';
$nagios{'admin_pager'} = 'pagenagios';
+ $nagios{'event_broker_options'} = '0';
+ $nagios{'broker_module'} = '';
return %nagios;
}



Log in to comment.




Attached File

No Files Currently Attached

Changes ( 2 )

Field Old Value Date By
status_id Open 2007-01-09 01:59 itgroundwork
close_date - 2007-01-09 01:59 itgroundwork