*Change the jenkins/hudson test scripts
[shinken.git] / etc / shinken-specific-high-availability.cfg
blob5694fb09c7bc2e48bad44ab6d269042eed224c0b
1 #This config file defined Shinken specific objects like
2 #satellites or Realms
4 #This file is for defined a pure high availability environnement
5 #That mean that if a satellite die, it will be replaced
6 #There is only one Realm with every one into it
7 #All you need to to is to change address from node1 and node2
8 #with the DNS names of yours servers
11 #The scheduler is a "Host manager". It get hosts and theirs
12 #services. It scheduler checks for them.
13 define scheduler{
14        scheduler_name   scheduler-master
15        address  node1
16        port     7768
17        spare    0       ;is not a spare
18        realm    All
19        weight           1       ;optionnal : 1
20        }
23 #The second scheduler, the slave one
24 define scheduler{
25        scheduler_name   scheduler-slave
26        address  node2
27        port     7768
28        spare    1       ;is a spare
29        realm    All
30        weight           1       ;optionnal : 1
31        }
34 #Reactionner launch notifications
35 define reactionner{
36        reactionner_name reactionner-master
37        address  node1
38        port     7769
39        spare    0
40        realm    All
41        manage_sub_realms 0      ;optionnal : 1
42        min_workers       1      ;optionnal : 1
43        max_workers       15     ;optionnal : 30
44        polling_interval         1       ;optionnal : 1
45        }
48 #Reactionner launch notifications
49 #The slave one
50 define reactionner{
51        reactionner_name reactionner-slave
52        address  node2
53        port     7769
54        spare    1
55        realm    All
56        manage_sub_realms 0      ;optionnal : 1
57        min_workers       1      ;optionnal : 1
58        max_workers       15     ;optionnal : 30
59        polling_interval         1       ;optionnal : 1
60        }
63 #Poller are here to launch checks
64 define poller{
65        poller_name     poller-master
66        address  node1
67        port     7771
68        realm    All
69        spare    0
70        manage_sub_realms 0      ;optionnal : 0
71        min_workers       4      ;optionnal : 1
72        max_workers       4      ;optionnal : 30
73        processes_by_worker      256        ;optionnal : 256
74        polling_interval         1       ;optionnal : 1
78 #Poller are here to launch checks
79 define poller{
80        poller_name     poller-slave
81        address  node2
82        port     7771
83        realm    All
84        spare    1
85        manage_sub_realms 0      ;optionnal : 0
86        min_workers       4      ;optionnal : 1
87        max_workers       4      ;optionnal : 30
88        processes_by_worker      256        ;optionnal : 256
89        polling_interval         1       ;optionnal : 1
93 #The arbiter definition is important : without 2 defined arbiter,
94 #no high availability
95 define arbiter{
96        arbiter_name     Arbiter-master
97        host_name        node1       ;result of the get_hostname.py command (or hostname under Unix)
98        address  node1
99        port     7770
100        spare    0
101        #modules          No module for now
102        }
104 #The arbiter definition is optionnal
105 #Like reactionner and broker, it do not need load balanced
106 define arbiter{
107        arbiter_name     Arbiter-slave
108        host_name        node2       ;result of the get_hostname.py command (or hostname under Unix)
109        address  node2
110        port     7770
111        spare    1
112        #modules          No module for now
113        }
117 #The broker manage data export (in flat file or in database)
118 #Here just log files and status.dat file
119 define broker{
120        broker_name      broker-master
121        address  node1
122        port     7772
123        spare    0
124        realm    All
125        manage_sub_realms 1
126        manage_arbiters   1
127        modules           Status-Dat, Simple-log
128        }
132 #The broker manage data export (in flat file or in database)
133 #Here just log files and status.dat file
134 define broker{
135        broker_name      broker-slave
136        address  node2
137        port     7772
138        spare    1
139        realm    All
140        manage_sub_realms 1
141        manage_arbiters   1
142        modules           Status-Dat, Simple-log
143        }
146 ##Now the modules for broker
148 #Here the NDO/MySQL module
149 #So you can use with NagVis or Centreon
150 define module{
151        module_name      ToNdodb_Mysql
152        module_type      ndodb_mysql
153        database         ndo      ; database name
154        user             root     ; user of the database
155        password         root     ; must be changed
156        host             localhost ; host to connect
157        character_set    utf8     ;optionnal, UTF8 is the default
160 #Here a NDO/Oracle module. For Icinga web connexion
161 #Or for database admin that do not like MySQL
162 define module{
163        module_name      ToNdodb_Oracle
164        module_type      ndodb_oracle
165        database         XE              ;database name (listener in fact)
166        user             system
167        password         password        ;Yes I know I have to change my default password...
168        oracle_home      /usr/lib/oracle/xe/app/oracle/product/10.2.0/server     ;optional
172 #Here for Merlin/MySQL. for Ninja connexion
173 define module{
174        module_name      ToMerlindb_Mysql
175        module_type      merlindb
176        backend          mysql    ;backend to use, here mysql databse
177        database         merlin   ;database name
178        user             root
179        password         root
180        host             localhost
181        character_set    utf8     ;optionnal, UTF8 is the default
185 #Here the Merlin/Sqlite. No one use it for now :)
186 define module{
187        module_name      ToMerlindb_Sqlite
188        module_type      merlindb
189        backend          sqlite    ;like the mysql, but sqlite :)
190        database_path    /tmp/mabase.sqlite  ;path of the sqlite file
194 #Here the couchdb export. Maybe use one day...
195 define module{
196        module_name      ToCouchdb
197        module_type      couchdb
198        user             root
199        password         root
200        host             localhost
204 #Export services perfdata to file
205 define module{
206        module_name      Service-Perfdata
207        module_type      service_perfdata
208        path             /usr/local/shinken/var/service-perfdata
212 #For hosts this time
213 define module{
214        module_name      Host-Perfdata
215        module_type      host_perfdata
216        path             /usr/local/shinken/var/host-perfdata
220 #The log managment
221 define module{
222        module_name      Simple-log
223        module_type      simple_log
224        path             /usr/local/shinken/var/nagios.log
228 #Status.dat and objects.cache export. For the old Nagios
229 #interface
230 define module{
231        module_name      Status-Dat
232        module_type      status_dat
233        status_file      /usr/local/shinken/var/status.dat
234        object_cache_file        /usr/local/shinken/var/objects.cache
235        status_update_interval   15
239 #A global Realm
240 define realm{
241        realm_name  All
242        default          1
248 ##Now addon about standard configuration :
249 #resultmodulation : change "on te fly" a check result, without negate or something like it
250 #escalation : like service_escalation, but a generic that host/service can call
252 #A result modulation is use to module a check result, like CRITICAL->WARNING here
253 define resultmodulation{
254        resultmodulation_name     critical_is_warning           ;required
255        exit_codes_match          2                ;optionnal, list of code to change
256        output_match              //               ;optionnal, regexp for activation of exit_code if output match
257        exit_code_modulation      1                ;code that will be put if the code match
258        output_modulation         s///        ;optionnal regexp to change output
259        longoutput_modulation     s///      ;optionnal regexp to change long_output
260        modulation_period         24×7    ;period when to apply the modulation
264 #Escalation is a generic version of service_escalation and host_escalation
265 #It can be called by services/hosts so it will be far more easier to be
266 #configured
267 define escalation{
268        escalation_name          ToLevel2           ;required
269        first_notification       2
270        last_notification        5
271        notification_interval    1
272        escalation_period        24x7          ;optionnal, if none, always true
273        escalation_options       d,u,r,w,c     ,optionnal, if none, all states (d,u,r,w,c)
274        contacts                 dbrosseau
275 #       contact_groups          admins