]> granicus.if.org Git - icinga2/blob - doc/14-appendix.md
beaea1680b544b8f9c11c4f70bb2062b3c4da585
[icinga2] / doc / 14-appendix.md
1 # <a id="appendix"></a> Appendix
2
3 ## <a id="external-commands-list-detail"></a> External Commands List
4
5 Additional details can be found in the [Icinga 1.x Documentation](http://docs.icinga.org/latest/en/extcommands2.html)
6
7   Command name                              | Parameters                        | Description
8   ------------------------------------------|-----------------------------------|--------------------------
9   PROCESS_HOST_CHECK_RESULT                 | ;&lt;host_name&gt;;&lt;status_code&gt;;&lt;plugin_output&gt; (3) | -
10   PROCESS_SERVICE_CHECK_RESULT              | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;return_code&gt;;&lt;plugin_output&gt; (4) | -
11   SCHEDULE_HOST_CHECK                       | ;&lt;host_name&gt;;&lt;check_time&gt; (2)  | -
12   SCHEDULE_FORCED_HOST_CHECK                | ;&lt;host_name&gt;;&lt;check_time&gt; (2)  | -
13   SCHEDULE_SVC_CHECK                        | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_time&gt; (3)  | -
14   SCHEDULE_FORCED_SVC_CHECK                 | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_time&gt; (3)  | -
15   ENABLE_HOST_CHECK                         | ;&lt;host_name&gt; (1)  | -
16   DISABLE_HOST_CHECK                        | ;&lt;host_name&gt; (1) | -
17   ENABLE_SVC_CHECK                          | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
18   DISABLE_SVC_CHECK                         | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
19   SHUTDOWN_PROCESS                          | - | -
20   RESTART_PROCESS                           | - | -
21   SCHEDULE_FORCED_HOST_SVC_CHECKS           | ;&lt;host_name&gt;;&lt;check_time&gt; (2)  | -
22   SCHEDULE_HOST_SVC_CHECKS                  | ;&lt;host_name&gt;;&lt;check_time&gt; (2)  | -
23   ENABLE_HOST_SVC_CHECKS                    | ;&lt;host_name&gt; (1) | -
24   DISABLE_HOST_SVC_CHECKS                   | ;&lt;host_name&gt; (1) | -
25   ACKNOWLEDGE_SVC_PROBLEM                   | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;sticky&gt;;&lt;notify&gt;;&lt;persistent&gt;;&lt;author&gt;;&lt;comment&gt; (7) | Note: Icinga 2 treats all comments as persistent.
26   ACKNOWLEDGE_SVC_PROBLEM_EXPIRE            | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;sticky&gt;;&lt;notify&gt;;&lt;persistent&gt;;&lt;timestamp&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | Note: Icinga 2 treats all comments as persistent.
27   REMOVE_SVC_ACKNOWLEDGEMENT                | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
28   ACKNOWLEDGE_HOST_PROBLEM                  | ;&lt;host_name&gt;;&lt;sticky&gt;;&lt;notify&gt;;&lt;persistent&gt;;&lt;author&gt;;&lt;comment&gt; (6) | Note: Icinga 2 treats all comments as persistent.
29   ACKNOWLEDGE_HOST_PROBLEM_EXPIRE           | ;&lt;host_name&gt;;&lt;sticky&gt;;&lt;notify&gt;;&lt;persistent&gt;;&lt;timestamp&gt;;&lt;author&gt;;&lt;comment&gt; (7) | Note: Icinga 2 treats all comments as persistent.
30   REMOVE_HOST_ACKNOWLEDGEMENT               | ;&lt;host_name&gt; (1)  | -
31   DISABLE_HOST_FLAP_DETECTION               | ;&lt;host_name&gt; (1)  | -
32   ENABLE_HOST_FLAP_DETECTION                | ;&lt;host_name&gt; (1)  | -
33   DISABLE_SVC_FLAP_DETECTION                | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
34   ENABLE_SVC_FLAP_DETECTION                 | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
35   ENABLE_HOSTGROUP_SVC_CHECKS               | ;&lt;hostgroup_name&gt; (1)  | -
36   DISABLE_HOSTGROUP_SVC_CHECKS              | ;&lt;hostgroup_name&gt; (1)  | -
37   ENABLE_SERVICEGROUP_SVC_CHECKS            | ;&lt;servicegroup_name&gt; (1)  | -
38   DISABLE_SERVICEGROUP_SVC_CHECKS           | ;&lt;servicegroup_name&gt; (1)  | -
39   ENABLE_PASSIVE_HOST_CHECKS                | ;&lt;host_name&gt; (1)  | -
40   DISABLE_PASSIVE_HOST_CHECKS               | ;&lt;host_name&gt; (1)  | -
41   ENABLE_PASSIVE_SVC_CHECKS                 | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
42   DISABLE_PASSIVE_SVC_CHECKS                | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
43   ENABLE_SERVICEGROUP_PASSIVE_SVC_CHECKS    | ;&lt;servicegroup_name&gt; (1)  | -
44   DISABLE_SERVICEGROUP_PASSIVE_SVC_CHECKS   | ;&lt;servicegroup_name&gt; (1)  | -
45   ENABLE_HOSTGROUP_PASSIVE_SVC_CHECKS       | ;&lt;hostgroup_name&gt; (1)  | -
46   DISABLE_HOSTGROUP_PASSIVE_SVC_CHECKS      | ;&lt;hostgroup_name&gt; (1)  | -
47   PROCESS_FILE                              | ;&lt;file_name&gt;;&lt;delete&gt; (2)  | -
48   SCHEDULE_SVC_DOWNTIME                     | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (9)  | -
49   DEL_SVC_DOWNTIME                          | ;&lt;downtime_id&gt; (1)   | -
50   SCHEDULE_HOST_DOWNTIME                    | ;&lt;host_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
51   DEL_HOST_DOWNTIME                         | ;&lt;downtime_id&gt; (1)  | -
52   SCHEDULE_HOST_SVC_DOWNTIME                | ;&lt;host_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
53   SCHEDULE_HOSTGROUP_HOST_DOWNTIME          | ;&lt;hostgroup_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
54   SCHEDULE_HOSTGROUP_SVC_DOWNTIME           | ;&lt;hostgroup_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
55   SCHEDULE_SERVICEGROUP_HOST_DOWNTIME       | ;&lt;servicegroup_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
56   SCHEDULE_SERVICEGROUP_SVC_DOWNTIME        | ;&lt;servicegroup_name&gt;;&lt;start_time&gt;;&lt;end_time&gt;;&lt;fixed&gt;;&lt;trigger_id&gt;;&lt;duration&gt;;&lt;author&gt;;&lt;comment&gt; (8)  | -
57   ADD_HOST_COMMENT                          | ;&lt;host_name&gt;;&lt;persistent&gt;;&lt;author&gt;;&lt;comment&gt; (4)  | Note: Icinga 2 treats all comments as persistent.
58   DEL_HOST_COMMENT                          | ;&lt;comment_id&gt; (1)  | -
59   ADD_SVC_COMMENT                           | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;persistent&gt;;&lt;author&gt;;&lt;comment&gt; (5)  | Note: Icinga 2 treats all comments as persistent.
60   DEL_SVC_COMMENT                           | ;&lt;comment_id&gt; (1)  | -
61   DEL_ALL_HOST_COMMENTS                     | ;&lt;host_name&gt; (1)  | -
62   DEL_ALL_SVC_COMMENTS                      | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
63   SEND_CUSTOM_HOST_NOTIFICATION             | ;&lt;host_name&gt;;&lt;options&gt;;&lt;author&gt;;&lt;comment&gt; (4)  | -
64   SEND_CUSTOM_SVC_NOTIFICATION              | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;options&gt;;&lt;author&gt;;&lt;comment&gt; (5)  | -
65   DELAY_HOST_NOTIFICATION                   | ;&lt;host_name&gt;;&lt;notification_time&gt; (2)  | -
66   DELAY_SVC_NOTIFICATION                    | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;notification_time&gt; (3)  | -
67   ENABLE_HOST_NOTIFICATIONS                 | ;&lt;host_name&gt; (1)  | -
68   DISABLE_HOST_NOTIFICATIONS                | ;&lt;host_name&gt; (1)  | -
69   ENABLE_SVC_NOTIFICATIONS                  | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
70   DISABLE_SVC_NOTIFICATIONS                 | ;&lt;host_name&gt;;&lt;service_name&gt; (2) | -
71   DISABLE_HOSTGROUP_HOST_CHECKS             | ;&lt;hostgroup_name&gt; (1)  | -
72   DISABLE_HOSTGROUP_PASSIVE_HOST_CHECKS     | ;&lt;hostgroup_name&gt; (1)  | -
73   DISABLE_SERVICEGROUP_HOST_CHECKS          | ;&lt;servicegroup_name&gt; (1)  | -
74   DISABLE_SERVICEGROUP_PASSIVE_HOST_CHECKS  | ;&lt;servicegroup_name&gt; (1)  | -
75   ENABLE_HOSTGROUP_HOST_CHECKS              | ;&lt;hostgroup_name&gt; (1)  | -
76   ENABLE_HOSTGROUP_PASSIVE_HOST_CHECKS      | ;&lt;hostgroup_name&gt; (1) | -
77   ENABLE_SERVICEGROUP_HOST_CHECKS           | ;&lt;servicegroup_name&gt; (1)  | -
78   ENABLE_SERVICEGROUP_PASSIVE_HOST_CHECKS   | ;&lt;servicegroup_name&gt; (1)  | -
79   ENABLE_NOTIFICATIONS                      | -  | -
80   DISABLE_NOTIFICATIONS                     | -   | -
81   ENABLE_FLAP_DETECTION                     | -  | -
82   DISABLE_FLAP_DETECTION                    | -  | -
83   ENABLE_EVENT_HANDLERS                     | -  | -
84   DISABLE_EVENT_HANDLERS                    | -  | -
85   ENABLE_PERFORMANCE_DATA                   | -  | -
86   DISABLE_PERFORMANCE_DATA                  | -  | -
87   START_EXECUTING_HOST_CHECKS               | -  | -
88   STOP_EXECUTING_HOST_CHECKS                | -  | -
89   START_EXECUTING_SVC_CHECKS                | -  | -
90   STOP_EXECUTING_SVC_CHECKS                 | -  | -
91   CHANGE_SVC_MODATTR                        | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;value&gt; (3)  | -
92   CHANGE_HOST_MODATTR                       | ;&lt;host_name&gt;;&lt;value&gt; (2)  | -
93   CHANGE_USER_MODATTR                       | ;&lt;user_name&gt;;&lt;value&gt; (2)  | -
94   CHANGE_CHECKCOMMAND_MODATTR               | ;&lt;checkcommand_name&gt;;&lt;value&gt; (2)  | -
95   CHANGE_EVENTCOMMAND_MODATTR               | ;&lt;eventcommand_name&gt;;&lt;value&gt; (2)  | -
96   CHANGE_NOTIFICATIONCOMMAND_MODATTR        | ;&lt;notificationcommand_name&gt;;&lt;value&gt; (2)  | -
97   CHANGE_NORMAL_SVC_CHECK_INTERVAL          | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_interval&gt; (3)  | -
98   CHANGE_NORMAL_HOST_CHECK_INTERVAL         | ;&lt;host_name&gt;;&lt;check_interval&gt; (2)  | -
99   CHANGE_RETRY_SVC_CHECK_INTERVAL           | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_interval&gt; (3)  | -
100   CHANGE_RETRY_HOST_CHECK_INTERVAL          | ;&lt;host_name&gt;;&lt;check_interval&gt; (2) | -
101   ENABLE_HOST_EVENT_HANDLER                 | ;&lt;host_name&gt; (1)  | -
102   DISABLE_HOST_EVENT_HANDLER                | ;&lt;host_name&gt; (1)  | -
103   ENABLE_SVC_EVENT_HANDLER                  | ;&lt;host_name&gt;;&lt;service_name&gt; (2)  | -
104   DISABLE_SVC_EVENT_HANDLER                 | ;&lt;host_name&gt;;&lt;service_name&gt; (2) | -
105   CHANGE_HOST_EVENT_HANDLER                 | ;&lt;host_name&gt;;&lt;event_command_name&gt; (2)  | -
106   CHANGE_SVC_EVENT_HANDLER                  | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;event_command_name&gt; (3)  | -
107   CHANGE_HOST_CHECK_COMMAND                 | ;&lt;host_name&gt;;&lt;check_command_name&gt; (2)  | -
108   CHANGE_SVC_CHECK_COMMAND                  | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_command_name&gt; (3)  | -
109   CHANGE_MAX_HOST_CHECK_ATTEMPTS            | ;&lt;host_name&gt;;&lt;check_attempts&gt; (2)  | -
110   CHANGE_MAX_SVC_CHECK_ATTEMPTS             | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;check_attempts&gt; (3)  | -
111   CHANGE_HOST_CHECK_TIMEPERIOD              | ;&lt;host_name&gt;;&lt;timeperiod_name&gt; (2)   | -
112   CHANGE_SVC_CHECK_TIMEPERIOD               | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;timeperiod_name&gt;  | -
113   CHANGE_CUSTOM_HOST_VAR                    | ;&lt;host_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (3)  | -
114   CHANGE_CUSTOM_SVC_VAR                     | ;&lt;host_name&gt;;&lt;service_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (4)  | -
115   CHANGE_CUSTOM_USER_VAR                    | ;&lt;user_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (3)  | -
116   CHANGE_CUSTOM_CHECKCOMMAND_VAR            | ;&lt;check_command_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (3)  | -
117   CHANGE_CUSTOM_EVENTCOMMAND_VAR            | ;&lt;event_command_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (3)  | -
118   CHANGE_CUSTOM_NOTIFICATIONCOMMAND_VAR     | ;&lt;notification_command_name&gt;;&lt;var_name&gt;;&lt;var_value&gt; (3)  | -
119   ENABLE_HOSTGROUP_HOST_NOTIFICATIONS       | ;&lt;hostgroup_name&gt; (1) | -
120   ENABLE_HOSTGROUP_SVC_NOTIFICATIONS        | ;&lt;hostgroup_name&gt; (1)  | -
121   DISABLE_HOSTGROUP_HOST_NOTIFICATIONS      | ;&lt;hostgroup_name&gt; (1)  | -
122   DISABLE_HOSTGROUP_SVC_NOTIFICATIONS       | ;&lt;hostgroup_name&gt; (1)  | -
123   ENABLE_SERVICEGROUP_HOST_NOTIFICATIONS    | ;&lt;servicegroup_name&gt; (1)  | -
124   DISABLE_SERVICEGROUP_HOST_NOTIFICATIONS   | ;&lt;servicegroup_name&gt; (1)  | -
125   ENABLE_SERVICEGROUP_SVC_NOTIFICATIONS     | ;&lt;servicegroup_name&gt; (1)  | -
126   DISABLE_SERVICEGROUP_SVC_NOTIFICATIONS    | ;&lt;servicegroup_name&gt; (1)  | -
127
128
129 ## <a id="schemas"></a> Schemas
130
131 By convention `CheckCommand`, `EventCommand`, and `NotificationCommand` objects
132 are exported using a prefix. This is mandatory for unique objects in the
133 command tables.
134
135 Object                  | Prefix
136 ------------------------|------------------------
137 CheckCommand            | check_
138 EventCommand            | event_
139 NotificationCommand     | notification_
140
141 ### <a id="schema-status-files"></a> Status Files
142
143 Status files used by Icinga 1.x Classic UI: `status.dat`, `objects.cache`.
144
145 Icinga 2 specific extensions:
146
147 * host and service objects support 'check_source' (added in Classic UI 1.10.0)
148 * command objects support custom variables (added in Classic UI 1.11.2)
149 * host and service objects support 'is_reachable' (added in Classic UI 1.11.3)
150 * 2.2 adds custom attributes with arrays and dictionaries. They are dumped as JSON encoded string and `_is_json`
151 is set as additional custom variable in `objects.cache`.
152
153 ### <a id="schema-db-ido"></a> DB IDO Schema
154
155 There is a detailed documentation for the Icinga IDOUtils 1.x
156 database schema available on [http://docs.icinga.org/latest/en/db_model.html]
157
158 #### <a id="schema-db-ido-extensions"></a> DB IDO Schema Extensions
159
160 Icinga 2 specific extensions are shown below:
161
162 New tables: `endpoints`, `endpointstatus`
163
164   Table               | Column             | Type     | Default | Description
165   --------------------|--------------------|----------|---------|-------------
166   endpoints           | endpoint_object_id | bigint   | NULL    | FK: objects table
167   endpoints           | identity           | TEXT     | NULL    | endpoint name
168   endpoints           | node               | TEXT     | NULL    | local node name
169
170   Table               | Column             | Type     | Default | Description
171   --------------------|--------------------|----------|---------|-------------
172   endpointstatus      | endpoint_object_id | bigint   | NULL    | FK: objects table
173   endpointstatus      | identity           | TEXT     | NULL    | endpoint name
174   endpointstatus      | node               | TEXT     | NULL    | local node name
175   endpointstatus      | is_connected       | smallint | 0       | update on endpoint connect/disconnect
176
177 New columns:
178
179   Table               | Column                  | Type     | Default | Description
180   --------------------|-------------------------|----------|---------|-------------
181   all status/history  | endpoint_object_id      | bigint   | NULL    | FK: objects table
182   servicestatus       | check_source            | TEXT     | NULL    | node name where check was executed
183   hoststatus          | check_source            | TEXT     | NULL    | node name where check was executed
184   statehistory        | check_source            | TEXT     | NULL    | node name where check was executed
185   servicestatus       | is_reachable            | integer  | NULL    | object reachability
186   hoststatus          | is_reachable            | integer  | NULL    | object reachability
187   logentries          | object_id               | bigint   | NULL    | FK: objects table (service associated with column)
188   {host,service}group | notes                   | TEXT     | NULL    | -
189   {host,service}group | notes_url               | TEXT     | NULL    | -
190   {host,service}group | action_url              | TEXT     | NULL    | -
191   customvariable*     | is_json                 | integer  | 0       | Defines whether `varvalue` is a json encoded string from custom attributes, or not
192
193 Additional command custom variables populated from 'vars' dictionary.
194 Additional global custom variables populated from 'Vars' constant (object_id is NULL).
195
196 ### <a id="schema-livestatus"></a> Livestatus Schema
197
198 #### <a id="schema-livestatus-extensions"></a> Livestatus Schema Extensions
199
200 Icinga 2 specific extensions are shown below:
201
202 New table: `endpoints`
203
204   Table     | Column
205   ----------|--------------
206   endpoints | name
207   endpoints | identity
208   endpoints | node
209   endpoints | is_connected
210
211 New columns:
212
213   Table     | Column
214   ----------|--------------
215   hosts     | is_reachable
216   services  | is_reachable
217   hosts     | cv_is_json
218   services  | cv_is_json
219   contacts  | cv_is_json
220   hosts     | check_source
221   services  | check_source
222   downtimes | triggers
223   downtimes | trigger_time
224   commands  | custom_variable_names
225   commands  | custom_variable_values
226   commands  | custom_variables
227   commands  | modified_attributes
228   commands  | modified_attributes_list
229   status    | custom_variable_names
230   status    | custom_variable_values
231   status    | custom_variables
232
233 Command custom variables reflect the local 'vars' dictionary.
234 Status custom variables reflect the global 'Vars' constant.
235
236 #### <a id="schema-livestatus-hosts-table-attributes"></a> Livestatus Hosts Table Attributes
237
238   Key                   | Type      | Note
239   ----------------------|-----------|-------------------------
240   name                  | string    | .
241   display_name          | string    | .
242   alias                 | string    | same as display_name.
243   address               | string    | .
244   address6              | string    | NEW in Icinga.
245   check_command         | string    | .
246   check_command_expanded | string   | .
247   event_handler         | string    | .
248   notification_period   | string    | host with notifications: period.
249   check_period          | string    | .
250   notes                 | string    | .
251   notes_expanded        | string    | .
252   notes_url             | string    | .
253   notes_url_expanded    | string    | .
254   action_url            | string    | .
255   action_url_expanded   | string    | .
256   plugin_output         | string    | .
257   perf_data             | string    | .
258   icon_image            | string    | .
259   icon_image_expanded   | string    | .
260   icon_image_alt        | stirng    | .
261   statusmap_image       | string    | .
262   long_plugin_output    | string    | .
263   max_check_attempts    | int       | .
264   flap_detection_enabled | int      | .
265   check_freshness       | int       | .
266   process_performance_data | int    | .
267   accept_passive_checks | int       | .
268   event_handler_enabled | int       | .
269   acknowledgement_type  | int       | Only 0 or 1.
270   check_type            | int       | .
271   last_state            | int       | .
272   last_hard_state       | int       | .
273   current_attempt       | int       | .
274   last_notification     | int       | host with notifications: last notification.
275   next_notification     | int       | host with notifications: next notification.
276   next_check            | int       | .
277   last_hard_state_change | int      | .
278   has_been_checked      | int       | .
279   current_notification_number | int | host with notifications: number.
280   total_services        | int       | .
281   checks_enabled        | int       | .
282   notifications_enabled | int       | .
283   acknowledged          | int       | .
284   state                 | int       | .
285   state_type            | int       | .
286   no_more_notifications | int       | notification_interval == 0 && volatile == false.
287   last_check            | int       | .
288   last_state_change     | int       | .
289   last_time_up          | int       | .
290   last_time_down        | int       | .
291   last_time_unreachable | int       | .
292   is_flapping           | int       | .
293   scheduled_downtime_depth | int    | .
294   active_checks_enabled | int       | .
295   modified_attributes   | array     | .
296   modified_attributes_list | array  | .
297   check_interval        | double    | .
298   retry_interval        | double    | .
299   notification_interval | double    | host with notifications: smallest interval.
300   low_flap_threshold    | double    | flapping_threshold
301   high_flap_threshold   | double    | flapping_threshold
302   latency               | double    | .
303   execution_time        | double    | .
304   percent_state_change  | double    | flapping.
305   in_notification_period | int      | host with notifications: matching period.
306   in_check_period       | int       | .
307   contacts              | array     | host with notifications, users and user groups.
308   downtimes             | array     | id.
309   downtimes_with_info   | array     | id+author+comment.
310   comments              | array     | id.
311   comments_with_info    | array     | id+author+comment.
312   comments_with_extra_info | array  | id+author+comment+entry_type+entry_time.
313   custom_variable_names | array     | .
314   custom_variable_values | array    | .
315   custom_variables      | array     | Array of custom variable array pair.
316   parents               | array     | Direct host parents.
317   childs                | array     | Direct host children (Note: `childs` is inherited from the origin MK_Livestatus protocol).
318   num_services          | int       | .
319   worst_service_state   | int       | All services and their worst state.
320   num_services_ok       | int       | All services with Ok state.
321   num_services_warn     | int       | All services with Warning state.
322   num_services_crit     | int       | All services with Critical state.
323   num_services_unknown  | int       | All services with Unknown state.
324   worst_service_hard_state | int    | All services and their worst hard state.
325   num_services_hard_ok  | int       | All services in a hard state with Ok state.
326   num_services_hard_warn | int      | All services in a hard state with Warning state.
327   num_services_hard_crit | int      | All services in a hard state with Critical state.
328   num_services_hard_unknown  | int  | All services in a hard state with Unknown state.
329   hard_state            | int       | Returns OK, if state is OK. Returns current state if now a hard state type. Returns last hard state otherwise.
330   staleness             | int       | Indicates time since last check normalized onto the check_interval.
331   groups                | array     | All hostgroups this host is a member of.
332   contact_groups        | array     | All usergroups associated with this host through notifications.
333   services              | array     | All services associated with this host.
334   services_with_state   | array     | All services associated with this host with state and hasbeenchecked.
335   services_with_info    | array     | All services associated with this host with state, hasbeenchecked and output.
336
337 Not supported: `initial_state`, `pending_flex_downtime`, `check_flapping_recovery_notification`,
338 `is_executing`, `check_options`, `obsess_over_host`, `first_notification_delay`, `x_3d`, `y_3d`, `z_3d`,
339 `x_2d`, `y_2d`, `filename`, `pnpgraph_present`.
340
341 #### <a id="schema-livestatus-hostgroups-table-attributes"></a> Livestatus Hostgroups Table Attributes
342
343   Key                   | Type      | Note
344   ----------------------|-----------|-------------------------
345   name                  | string    | .
346   alias                 | string    | `display_name` attribute.
347   notes                 | string    | .
348   notes_url             | string    | .
349   action_url            | string    | .
350   members               | array     | .
351   members_with_state    | array     | Host name and state.
352   worst_host_state      | int       | Of all group members.
353   num_hosts             | int       | In this group.
354   num_hosts_pending     | int       | .
355   num_hosts_up          | int       | .
356   num_hosts_down        | int       | .
357   num_hosts_unreach     | int       | .
358   num_services          | int       | Number of services associated with hosts in this hostgroup.
359   worst_services_state  | int       | .
360   num_services_pending  | int       | .
361   num_services_ok       | int       | .
362   num_services_warn     | int       | .
363   num_services_crit     | int       | .
364   num_services_unknown  | int       | .
365   worst_service_hard_state | int    | .
366   num_services_hard_ok | int        | .
367   num_services_hard_warn | int      | .
368   num_services_hard_crit | int      | .
369   num_services_hard_unknown | int   | .
370
371 #### <a id="schema-livestatus-services-table-attributes"></a> Livestatus Services Table Attributes
372
373   Key                   | Type      | Note
374   ----------------------|-----------|-------------------------
375   description           | string    | .
376   display_name          | string    | .
377   alias                 | string    | same as display_name.
378   check_command         | string    | .
379   check_command_expanded | string   | .
380   event_handler         | string    | .
381   notification_period   | string    | host with notifications: period.
382   check_period          | string    | .
383   notes                 | string    | .
384   notes_expanded        | string    | .
385   notes_url             | string    | .
386   notes_url_expanded    | string    | .
387   action_url            | string    | .
388   action_url_expanded   | string    | .
389   plugin_output         | string    | .
390   perf_data             | string    | .
391   icon_image            | string    | .
392   icon_image_expanded   | string    | .
393   icon_image_alt        | stirng    | .
394   statusmap_image       | string    | .
395   long_plugin_output    | string    | .
396   max_check_attempts    | int       | .
397   flap_detection_enabled | int      | .
398   check_freshness       | int       | .
399   process_performance_data | int    | .
400   accept_passive_checks | int       | .
401   event_handler_enabled | int       | .
402   acknowledgement_type  | int       | Only 0 or 1.
403   check_type            | int       | .
404   last_state            | int       | .
405   last_hard_state       | int       | .
406   current_attempt       | int       | .
407   last_notification     | int       | service with notifications: last notification.
408   next_notification     | int       | service with notifications: next notification.
409   next_check            | int       | .
410   last_hard_state_change | int      | .
411   has_been_checked      | int       | .
412   current_notification_number | int | service with notifications: number.
413   checks_enabled        | int       | .
414   notifications_enabled | int       | .
415   acknowledged          | int       | .
416   state                 | int       | .
417   state_type            | int       | .
418   no_more_notifications | int       | notification_interval == 0 && volatile == false.
419   last_check            | int       | .
420   last_state_change     | int       | .
421   last_time_up          | int       | .
422   last_time_down        | int       | .
423   last_time_unreachable | int       | .
424   is_flapping           | int       | .
425   scheduled_downtime_depth | int    | .
426   active_checks_enabled | int       | .
427   modified_attributes   | array     | .
428   modified_attributes_list | array  | .
429   check_interval        | double    | .
430   retry_interval        | double    | .
431   notification_interval | double    | service with notifications: smallest interval.
432   low_flap_threshold    | double    | flapping_threshold
433   high_flap_threshold   | double    | flapping_threshold
434   latency               | double    | .
435   execution_time        | double    | .
436   percent_state_change  | double    | flapping.
437   in_notification_period | int      | service with notifications: matching period.
438   in_check_period       | int       | .
439   contacts              | array     | service with notifications, users and user groups.
440   downtimes             | array     | id.
441   downtimes_with_info   | array     | id+author+comment.
442   comments              | array     | id.
443   comments_with_info    | array     | id+author+comment.
444   comments_with_extra_info | array  | id+author+comment+entry_type+entry_time.
445   custom_variable_names | array     | .
446   custom_variable_values | array    | .
447   custom_variables      | array     | Array of custom variable array pair.
448   hard_state            | int       | Returns OK, if state is OK. Returns current state if now a hard state type. Returns last hard state otherwise.
449   staleness             | int       | Indicates time since last check normalized onto the check_interval.
450   groups                | array     | All hostgroups this host is a member of.
451   contact_groups        | array     | All usergroups associated with this host through notifications.
452   host_                 | join      | Prefix for attributes from implicit join with hosts table.
453
454 Not supported: `initial_state`, `is_executing`, `check_options`, `obsess_over_service`, `first_notification_delay`,
455 `pnpgraph_present`.
456
457 #### <a id="schema-livestatus-servicegroups-table-attributes"></a> Livestatus Servicegroups Table Attributes
458
459   Key                   | Type      | Note
460   ----------------------|-----------|-------------------------
461   name                  | string    | .
462   alias                 | string    | `display_name` attribute.
463   notes                 | string    | .
464   notes_url             | string    | .
465   action_url            | string    | .
466   members               | array     | CSV format uses `host|service` syntax.
467   members_with_state    | array     | Host, service, hoststate, servicestate.
468   worst_service_state   | int       | .
469   num_services          | int       | .
470   num_services_pending  | int       | .
471   num_services_ok       | int       | .
472   num_services_warn     | int       | .
473   num_services_crit     | int       | .
474   num_services_unknown  | int       | .
475   num_services_hard_ok | int        | .
476   num_services_hard_warn | int      | .
477   num_services_hard_crit | int      | .
478   num_services_hard_unknown | int   | .
479
480 #### <a id="schema-livestatus-contacts-table-attributes"></a> Livestatus Contacts Table Attributes
481
482   Key                   | Type      | Note
483   ----------------------|-----------|-------------------------
484   name                  | string    | .
485   alias                 | string    | `display_name` attribute.
486   email                 | string    | .
487   pager                 | string    | .
488   host_notification_period | string | .
489   service_notification_period | string | .
490   host_notifications_enabled | int | .
491   service_notifications_enabled | int | .
492   in_host_notification_period | int | .
493   in_service_notification_period | int | .
494   custom_variable_names | array     | .
495   custom_variable_values | array    | .
496   custom_variables      | array     | Array of customvariable array pairs.
497   modified_attributes   | array     | .
498   modified_attributes_list | array  | .
499
500
501 Not supported: `can_submit_commands`.
502
503 #### <a id="schema-livestatus-contactgroups-table-attributes"></a> Livestatus Contactgroups Table Attributes
504
505   Key                   | Type      | Note
506   ----------------------|-----------|-------------------------
507   name                  | string    | .
508   alias                 | string    | `display_name` attribute.
509   members               | array     | .
510
511
512 #### <a id="schema-livestatus-commands-table-attributes"></a> Livestatus Commands Table Attributes
513
514   Key                   | Type      | Note
515   ----------------------|-----------|-------------------------
516   name                  | string    | 3 types of commands in Icinga 2.
517   line                  | string    | .
518
519
520 #### <a id="schema-livestatus-status-table-attributes"></a> Livestatus Status Table Attributes
521
522   Key                   | Type      | Note
523   ----------------------|-----------|-------------------------
524   connections           | int       | Since application start.
525   connections_rate      | double    | .
526   service_checks        | int       | Since application start.
527   service_checks_rate   | double    | .
528   host_checks           | int       | Since application start.
529   host_checks_rate      | double    | .
530   external_commands     | int       | Since application start.
531   external_commands_rate | double   | .
532   nagios_pid            | string    | Application PID.
533   enable_notifications  | int       | .
534   execute_service_checks | int      | .
535   accept_passive_service_checks | int | .
536   execute_host_checks   | int       | .
537   accept_passive_host_checks | int  | .
538   enable_event_handlers | int       | .
539   check_service_freshness | int     | .
540   check_host_freshness  | int       | .
541   enable_flap_detection | int       | .
542   process_performance_data | int    | .
543   check_external_commands | int     | Always enabled.
544   program_start         | int       | In seconds.
545   last_command_check    | int       | Always.
546   interval_length       | int       | Compatibility mode: 60.
547   num_hosts             | int       | .
548   num_services          | int       | .
549   program_version       | string    | 2.0.
550   livestatus_active_connections | string | .
551
552 Not supported: `neb_callbacks`, `neb_callbacks_rate`, `requests`, `requests_rate`, `forks`, `forks_rate`,
553 `log_messages`, `log_messages_rate`, `livechecks`, `livechecks_rate`, `livecheck_overflows`,
554 `livecheck_overflows_rate`, `obsess_over_services`, `obsess_over_hosts`, `last_log_rotation`,
555 `external_command_buffer_slots`, `external_command_buffer_usage`, `external_command_buffer_max`,
556 `cached_log_messages`, `livestatus_queued_connections`, `livestatus_threads`.
557
558
559 #### <a id="schema-livestatus-comments-table-attributes"></a> Livestatus Comments Table Attributes
560
561   Key                   | Type      | Note
562   ----------------------|-----------|-------------------------
563   author                | string    | .
564   comment               | string    | .
565   id                    | int       | legacy_id.
566   entry_time            | string    | Seconds.
567   type                  | int       | 1=host, 2=service.
568   is_service            | int       | .
569   persistent            | int       | Always.
570   source                | string    | Always external (1).
571   entry_type            | int       | .
572   expires               | int       | .
573   expire_time           | string    | Seconds.
574   service_              | join      | Prefix for attributes from implicit join with services table.
575   host_                 | join      | Prefix for attributes from implicit join with hosts table.
576
577
578 #### <a id="schema-livestatus-downtimes-table-attributes"></a> Livestatus Downtimes Table Attributes
579
580   Key                   | Type      | Note
581   ----------------------|-----------|-------------------------
582   author                | string    | .
583   comment               | string    | .
584   id                    | int       | legacy_id.
585   entry_time            | string    | Seconds.
586   type                  | int       | 1=active, 0=pending.
587   is_service            | int       | .
588   start_time            | string    | Seconds.
589   end_time              | string    | Seconds.
590   fixed                 | int       | 0=flexible, 1=fixed.
591   duration              | int       | .
592   triggered_by          | int       | legacy_id.
593   triggers              | int       | NEW in Icinga 2.
594   trigger_time          | string    | NEW in Icinga 2.
595   service_              | join      | Prefix for attributes from implicit join with services table.
596   host_                 | join      | Prefix for attributes from implicit join with hosts table.
597
598
599 #### <a id="schema-livestatus-timeperiod-table-attributes"></a> Livestatus Timeperiod Table Attributes
600
601   Key                   | Type      | Note
602   ----------------------|-----------|-------------------------
603   name                  | string    | .
604   alias                 | string    | `display_name` attribute.
605   in                    | int       | Current time is in timeperiod or not.
606
607 #### <a id="schema-livestatus-log-table-attributes"></a> Livestatus Log Table Attributes
608
609   Key                   | Type      | Note
610   ----------------------|-----------|-------------------------
611   time                  | int       | Time of log event (unix timestamp).
612   lineno                | int       | Line number in `CompatLogger` log file.
613   class                 | int       | Log message class: 0=info, 1=state, 2=program, 3=notification, 4=passive, 5=command.
614   message               | string    | Complete message line.
615   type                  | string    | Text before the colon `:`.
616   options               | string    | Text after the colon `:`.
617   comment               | string    | Comment if available.
618   plugin_output         | string    | Check output if available.
619   state                 | int       | Host or service state.
620   state_type            | int       | State type if available.
621   attempt               | int       | Current check attempt.
622   service_description   | string    | .
623   host_name             | string    | .
624   contact_name          | string    | .
625   command_name          | string    | .
626   current_service_      | join      | Prefix for attributes from implicit join with services table.
627   current_host_         | join      | Prefix for attributes from implicit join with hosts table.
628   current_contact_      | join      | Prefix for attributes from implicit join with contacts table.
629   current_command_      | join      | Prefix for attributes from implicit join with commands table.
630
631 #### <a id="schema-livestatus-statehist-table-attributes"></a> Livestatus Statehist Table Attributes
632
633   Key                   | Type      | Note
634   ----------------------|-----------|-------------------------
635   time                  | int       | Time of log event (unix timestamp).
636   lineno                | int       | Line number in `CompatLogger` log file.
637   from                  | int       | Start timestamp (unix timestamp).
638   until                 | int       | End timestamp (unix timestamp).
639   duration              | int       | until-from.
640   duration_part         | double    | duration / query_part.
641   state                 | int       | State: 0=ok, 1=warn, 2=crit, 3=unknown, -1=notmonitored.
642   host_down             | int       | Host associated with the service is down or not.
643   in_downtime           | int       | Host/service is in downtime.
644   in_host_downtime      | int       | Host associated with the service is in a downtime or not.
645   is_flapping           | int       | Host/service is flapping.
646   in_notification_period | int      | Host/service notification periods match or not.
647   notification_period   | string    | Host/service notification period.
648   host_name             | string    | .
649   service_description   | string    | .
650   log_output            | string    | Log file output for this state.
651   duration_ok           | int       | until-from for OK state.
652   duration_part_ok      | double    | .
653   duration_warning      | int       | until-from for Warning state.
654   duration_part_warning | double    | .
655   duration_critical     | int       | until-from for Critical state.
656   duration_part_critical | double    | .
657   duration_unknown      | int       | until-from for Unknown state.
658   duration_part_unknown | double    | .
659   duration_unmonitored  | int       | until-from for Not-Monitored state.
660   duration_part_unmonitored | double    | .
661   current_service_      | join      | Prefix for attributes from implicit join with services table.
662   current_host_         | join      | Prefix for attributes from implicit join with hosts table.
663
664 Not supported: `debug_info`.