]> granicus.if.org Git - icinga2/log
icinga2
11 years agocompatlog: refactor custom/acknowledgement notifications with author/commenttext
Michael Friedrich [Mon, 1 Jul 2013 09:17:58 +0000 (11:17 +0200)]
compatlog: refactor custom/acknowledgement notifications with author/commenttext

refs #4361

11 years agocompatlog: fix checkcommand name
Michael Friedrich [Mon, 1 Jul 2013 08:03:00 +0000 (10:03 +0200)]
compatlog: fix checkcommand name

refs #4361

11 years agoCompat: log notifications (wip)
Michael Friedrich [Fri, 28 Jun 2013 19:31:38 +0000 (21:31 +0200)]
Compat: log notifications (wip)

- we need a way to figure out which last commend id (or, author and
  text) where set when type is CUSTOM or ACKNOWLEDGEMENT
- GetCheckCommandName was required too
- not sure if notifications.cpp is the correct location

refs #4361
refs #3985
refs #2750

11 years agoicinga2.conf.dist: add CompatLog as default
Michael Friedrich [Fri, 28 Jun 2013 18:46:53 +0000 (20:46 +0200)]
icinga2.conf.dist: add CompatLog as default

11 years agoremoting: multicast messages into debug log
Michael Friedrich [Fri, 28 Jun 2013 17:50:23 +0000 (19:50 +0200)]
remoting: multicast messages into debug log

11 years agofix typo
Michael Friedrich [Fri, 28 Jun 2013 11:44:18 +0000 (13:44 +0200)]
fix typo

11 years agoadd downtime message (started,stopped,cancelled) and compat logger
Michael Friedrich [Fri, 28 Jun 2013 11:40:01 +0000 (13:40 +0200)]
add downtime message (started,stopped,cancelled) and compat logger

refs #3985
refs #2750

11 years agoUpdate the tutorial a bit.
Gunnar Beutner [Fri, 28 Jun 2013 07:04:49 +0000 (09:04 +0200)]
Update the tutorial a bit.

11 years agodocs: update latest changes
Michael Friedrich [Thu, 27 Jun 2013 12:53:26 +0000 (14:53 +0200)]
docs: update latest changes

fixes #4338

11 years agoImplement validator for timeperiods.
Gunnar Beutner [Thu, 27 Jun 2013 09:25:10 +0000 (11:25 +0200)]
Implement validator for timeperiods.

Fixes #3845

11 years agoMove filter constants to itl/constants.conf.
Gunnar Beutner [Thu, 27 Jun 2013 09:23:32 +0000 (11:23 +0200)]
Move filter constants to itl/constants.conf.

11 years agoCompat: split cr output into (long_)output, log only output
Michael Friedrich [Wed, 26 Jun 2013 16:23:59 +0000 (18:23 +0200)]
Compat: split cr output into (long_)output, log only output

status.dat requires output, and long_output seperated for proper
representation by guis and addons (they cannot be changed for
compatibility reasons, we must change).

logging an ALERT requires only the output (first line of the check
result output).

fixes #3882
fixes #4348

11 years agoconfigconvert: fix already replaced quotes escaping
Michael Friedrich [Wed, 26 Jun 2013 15:52:54 +0000 (17:52 +0200)]
configconvert: fix already replaced quotes escaping

refs #2743

11 years agoconfigconvert: update README
Michael Friedrich [Wed, 26 Jun 2013 14:23:19 +0000 (16:23 +0200)]
configconvert: update README

refs #2743

11 years agoconfigconvert: custom attr (CVs, *_url, notes, *image*, 2d_coords)
Michael Friedrich [Wed, 26 Jun 2013 14:01:22 +0000 (16:01 +0200)]
configconvert: custom attr (CVs, *_url, notes, *image*, 2d_coords)

collect attributes
* notes
* icon_image
* icon_image_alt
* action_url
* notes_url
* statusmap_image
* 2d_coords
* _CVs
* !__I2CONVERT

and stash it onto the custom dictionary.

note: attribute names starting with a number need to be quoted.

fixes #3096

11 years agoconfigconvert: update README (NOTES and TODO)
Michael Friedrich [Wed, 26 Jun 2013 12:29:57 +0000 (14:29 +0200)]
configconvert: update README (NOTES and TODO)

refs #2743

11 years agoconfigconvert: treat 'null' (disable inheritance) as '0' instead
Michael Friedrich [Wed, 26 Jun 2013 12:29:31 +0000 (14:29 +0200)]
configconvert: treat 'null' (disable inheritance) as '0' instead

refs #2743

11 years agoconfigconvert: fix 'n' and 'a' notification_options (filter = 0, filter = ...)
Michael Friedrich [Wed, 26 Jun 2013 12:12:38 +0000 (14:12 +0200)]
configconvert: fix 'n' and 'a' notification_options (filter = 0, filter = ...)

refs #4060

11 years agoconfigconvert: skip empty notification filters
Michael Friedrich [Wed, 26 Jun 2013 11:49:25 +0000 (13:49 +0200)]
configconvert: skip empty notification filters

refs #4060

11 years agoconfigconvert: disable some debug leftovers
Michael Friedrich [Wed, 26 Jun 2013 11:30:26 +0000 (13:30 +0200)]
configconvert: disable some debug leftovers

$ find -type f -name '*.pm' | xargs sed -i 's/[^#]say Dumper/ #say
Dumper/g'

11 years agoconfigconvert: notification_options -> notification_{state,type}_filter
Michael Friedrich [Wed, 26 Jun 2013 11:22:15 +0000 (13:22 +0200)]
configconvert: notification_options -> notification_{state,type}_filter

parsing the existing comma separated list and using some perl hash magic
to convert it to the new notification_type_filter and
notification_state_filter logic.

fixed missing file permission check on writing config files too.

fixes #4060

11 years agoMake the "custom" attribute a dictionary.
Gunnar Beutner [Wed, 26 Jun 2013 08:18:26 +0000 (10:18 +0200)]
Make the "custom" attribute a dictionary.

11 years agoFix syntax error.
Gunnar Beutner [Wed, 26 Jun 2013 08:01:44 +0000 (10:01 +0200)]
Fix syntax error.

11 years agoImplement notification_*_filter variables for Host/Service objects.
Gunnar Beutner [Wed, 26 Jun 2013 07:50:04 +0000 (09:50 +0200)]
Implement notification_*_filter variables for Host/Service objects.

11 years agoconfigconvert: notification* attributes for services and users
Michael Friedrich [Tue, 25 Jun 2013 15:59:30 +0000 (17:59 +0200)]
configconvert: notification* attributes for services and users

refs #2743

11 years agoconfigconvert: remove trailing whitespaces
Michael Friedrich [Tue, 25 Jun 2013 14:05:02 +0000 (16:05 +0200)]
configconvert: remove trailing whitespaces

11 years agoconfigconvert: rename unique notification object identifier
Michael Friedrich [Tue, 25 Jun 2013 14:00:29 +0000 (16:00 +0200)]
configconvert: rename unique notification object identifier

refs #2743

11 years agoconfigconvert: serviceescalations with servicegroup_name
Michael Friedrich [Tue, 25 Jun 2013 13:39:02 +0000 (15:39 +0200)]
configconvert: serviceescalations with servicegroup_name

requires a new functionality to grab all service names by a given
servicegroup name. this only works after reprocessing all services with
their updated "servicegroups" attribute as array in the 2.x objects
hive.

after fetching the service names and their logical objects, it's quite
the same procedure as for the hostgroups and single
host_names/service_descriptions - for better reading, code remains
duplicated for now.

furthermore, escalation notification template objects are only added
based on the old contact->notification_command, and only a reference
template added when using within the service linking.

refs #4009

11 years agoconfigconvert: only export servicegroups when available
Michael Friedrich [Tue, 25 Jun 2013 11:16:10 +0000 (13:16 +0200)]
configconvert: only export servicegroups when available

refs #2743

11 years agoconfigconvert: convert service escalation to notification escalation logic
Michael Friedrich [Mon, 24 Jun 2013 20:15:00 +0000 (22:15 +0200)]
configconvert: convert service escalation to notification escalation logic

- fixed bug with contactgroups in plain notifications
- fix bug with duplicated notifications (duplicate detection logic based
  on names, not template names)
- contacts may use templates too, and hide required values there
  (commands)
- added attribute getters which take templates into account (required
  for service -> notification_interval multiplied with service escalation
  first|last_notification too)
- apply the service escalation -> users -> commands as well as linking
  new notification with users, and services, defined either with
  * host_name/service_description
  * hostgroup_name/service_description
  * servicegroup_name (TODO)
- code duplication due to many nested loops with group wildcards

in short - we know why icinga 1.x takes ages to apply escalation.
because they look like added under pressure, and make no logical sense
compared to the rest. in short - they suck.

refs #4009

11 years agoImplement notification conditions.
Gunnar Beutner [Wed, 26 Jun 2013 07:08:50 +0000 (09:08 +0200)]
Implement notification conditions.

Fixes #2841

11 years agoMake sure flapping counters aren't negative.
Gunnar Beutner [Wed, 26 Jun 2013 06:52:06 +0000 (08:52 +0200)]
Make sure flapping counters aren't negative.

11 years agoConfig: Implement << and >> operators.
Gunnar Beutner [Wed, 26 Jun 2013 06:21:35 +0000 (08:21 +0200)]
Config: Implement << and >> operators.

11 years agoDon't allow asterisks in identifiers.
Gunnar Beutner [Tue, 25 Jun 2013 08:06:58 +0000 (10:06 +0200)]
Don't allow asterisks in identifiers.

11 years agoImplement script variables.
Gunnar Beutner [Tue, 25 Jun 2013 07:21:25 +0000 (09:21 +0200)]
Implement script variables.

11 years agoconfigconvert: treat address* and other attributes directly as macros
Michael Friedrich [Mon, 24 Jun 2013 15:03:34 +0000 (17:03 +0200)]
configconvert: treat address* and other attributes directly as macros

also for user attributes.

fixes #4333

11 years agoconfigconvert: update README
Michael Friedrich [Mon, 24 Jun 2013 14:19:58 +0000 (16:19 +0200)]
configconvert: update README

refs #2743

11 years agoconfigconvert: move to tools/
Michael Friedrich [Mon, 24 Jun 2013 14:14:20 +0000 (16:14 +0200)]
configconvert: move to tools/

fixes #4337

11 years agotools: move mkembedconfig into subdir
Michael Friedrich [Mon, 24 Jun 2013 13:57:11 +0000 (15:57 +0200)]
tools: move mkembedconfig into subdir

preparation for moving the conversion script into tools/

refs #4337

11 years agoconfigconvert: disable debug logging by default
Michael Friedrich [Mon, 24 Jun 2013 13:19:13 +0000 (15:19 +0200)]
configconvert: disable debug logging by default

11 years agoconfigconvert: run_icinga2 config test helper
Michael Friedrich [Mon, 24 Jun 2013 13:00:13 +0000 (15:00 +0200)]
configconvert: run_icinga2 config test helper

11 years agoconfigconvert: enable debug consolelogger for config test
Michael Friedrich [Mon, 24 Jun 2013 12:55:18 +0000 (14:55 +0200)]
configconvert: enable debug consolelogger for config test

11 years agoconfigconvert: remove obsolete itl service template
Michael Friedrich [Mon, 24 Jun 2013 07:33:39 +0000 (09:33 +0200)]
configconvert: remove obsolete itl service template

11 years agoConfig Conversion: add conversion script
Michael Friedrich [Tue, 12 Mar 2013 16:40:53 +0000 (17:40 +0100)]
Config Conversion: add conversion script

Squashed Rebase, commit msg below.

convertv1->v2 initial import

refs #2743

itl: fix inclusion of notification.conf

Config Conversion: command macros, templates

refs #2743

WIP: try resolving the host->svc relation from templates and tricks

not finished yet, there's heavy recursion required

WIP configconversion: rewrite recursive lookup of linked host_name/service_description

this is a mess. configs may just use "name" instead of "host_name" on
type "host", same goes for service and service_descriptions. well, and
if it's a template, "name" is populated too.

the algorithm is not clean enough, and does not scale at all. there are
bugs, and the hostgroup linking is not yet taken into account too.

basics host -> service dumping of v2 config is implemented.

refs #2743

ConfigConvert: split into modules, add objects.cache read, dump cmd line

basically it works with

- dumping a host with all services, using templates
- check_command and all arguments/user macros translation
- reading the objects.cache file location from icinga.cfg
=> this is reserved only for getting dedicated relations
=> we do not want to duplicate the work of xodtemplate.c in perl here
- all important functions have been split up into their respective
  modules in order to support better re-usage (i.e. lconfexport)

still missing important bits:

- detect service->group<-host links and build templates
- detect other ugly template methods
- dump templates
- the ugly deprecated normal|retry_check_interval mapping
- timeperiod mapping
- contact => user mapping
- notifications rework (dedicated object)
- dependencies, escalations (to be documented/implemented)
- the infamous rest

ConfigConvert: fix hash keys for convert/dump in perl 5.14

ConfigConvert: improved template handling, host/service dump 2x

refactored code again, removed nested loop bottlenecks. still, the
resolval of host_name/service_description requires more love.

templates are now correctly detected, linked, and printed in 2x syntax.
service templates are _not_ linked against host definitions in 2x as
this is not possible.

commands for hosts do not exist in 2x, therefore the command_name of an
1x host will be taken and guessed against its related services. if
there's a match, the service will be linked as 2x 'hostcheck'.

*_interval still needs proper handling, as the default interval is 1m,
but 2x requires the identifier.

ConfigConvert: refactor host_name/service_description link resolving

previous algorithm was buggy, as well get_host_name always looked up
host template objects, even if the template object was a service. this
is now fixed by re-using the __TYPE attribute (set on Icinga 1x config
read).

the algorithm is now like

                       |---------------------------------|
                      \/                                 |
                   svc_desc?                             |
                0 /        \ 1                           |
              use tmpl?    END -------> [svc_desc]       |
             0 /   \ 1                                   |
[undef] <- BROKEN  getobjbyattr(['use'], __TYPE, svcdesc |
                    |                                    |
                 getsvcdesc(obj)                         |
                    |                                    |
                    --------------------------------------

refs #2743

ConvertConfig: add basic support for users, timeperiods, *groups

as well as display_name as attribute to print something.

contact => user mapping is added as well, manipulating the __TYPE var
too. furthermore display_name on the host will be overwritten by the
alias, if set.

the groups don't dump much, only the display_name if set. their dump
function is implemented generic, based on the __TYPE

ConfigConvert: fix 4 little big thinkos on import/convert/dump

1) do not skip lines containing ;.* - there may actually be a comment on
attr->val line. rather clean the line safely, and let the magic happen.

2) the type counter was implemented in order to have unique object ids
by type, since 1x config does not provide us with such. problem - the
function had a local var, saving the counter for each file, overwriting
the hash attributes later on, starting again with 0. nasty bug, hard to
figure out. fixed by feeding the type_cnt into the cfg_obj hive for now.
revamped the state machine logic as well, like so

I: define TYPE {  --> __TYPE = TYPE
II: attr val --> {type}->{type_cnt->cnt}->{attr} = val
III: } --> type_cnt->cnt++
IV: <empty/comment>

3) also skip service templates (__IS_TEMPLATE) sooner, and do not try to
calculate some host_name/service_description magic out of them - they
just can't go down one level to the host, but only up with 'use'.

4) host and service templates on 2x config dump must check if
__USES_TEMPLATE is actually set to 1, checking for defined is not
enough.

whatthecommit.com:

A long time ago, in a galaxy far far away...

refs #2743

ConfigConvert: add more host/service attributes, groups

*_interval are automatically mapped, while the *groups attribute it
converted into an array in order to easily stash more groups on it.

still a todo - loop over existing groups and re-link their members into
the respective objects, as 2.x only supports that location.

fix for the host->service relation - use the already processed service
2x hashref in order to do some magic with host->{'SERVICE'} = service

all 2x attributes are now encapsulated with "", to stay safe.
todo - more generic config 2x dump.

furthermore, add some more code comments for the respective sections.

refs #2743

ConfigConvert: fix service linking not unique, add hostgroup->members re-link to host->hostgroups

while working on the missing servicegroups and their facepalm members
syntax (host1,svc1,host2,svc2 - awesome to parse), i figured that the
whole detection of services by their attribute 'service_description' is
not uniquely implemented. now the getter functions are duplicated, and
not modular anymore, for the sake of having a service identified by its
host_name + service_description. since that lookup is recursive, we must
pass the host_name from the very beginning - otherwise we could
accidently overwrite that with a template entry.

the hostgroup re-linking works, also thanks to the fact that the inner
object structure is just an array in the hashref, which allows smart
push.

contact/user groups are tricky again due to the different naming.

further todo: sort all macros and hostservice links. right now this
looks like chaos.

refs #2743

ConfigConvert: basic servicegroup parsing method

ConfigConvert: refactor multiple host_name's on service object detection

this is ugly. a service object may contain 'host_name' with
'host1,host2,host3' and so on. treating this as string won't allow us to
look into the template tree for valid host attributes, so we need to
rewrite the getter function, allowing some special treatment on
host_name arrays.

for the service object preparation this means: while in the service
loop, we need to loop again over all hosts, then dclone the hashref
object for the service, and add the unique host_name attribute again.

we might require some loop unrolling later, but for now this works as
expected.

refs #2743

ConvertConfig: disable debug output, some reformatting of dump

ConfigConvert: refactor host-svc links, add full service/usergroup relinking

due to the relinking afterwards we actually modify the service objects
already prepared for 2x. since the *group magic depends on the
host/services/users already prepared, we get a perpetuum mobile here
with the host loop and resolving service relations.

in order to safely fix the issue, there's a seperate host-service link
loop after resolving all the other needed objects, which may cost a
little bit more performance, but is safe and standalone, getting all
previous modifications, migrations and also hacks.

next to the refactored flow, the issue with resolving the correct
servicegroups and stashing them into an array is solved, as well as
converting the existing contactgroups to usergroups, as well as
re-linking existing contactgroup->members to their new home,
user->usergroups.

note: when parsing the servicegroup members into an array, it must not
be sorted afterwards, because we will shift 2 objects (host, service) in
order to identify the correct service object for adding the servicegroup
item.

some code reorganisation too, plus a minor comma fix for the host
address macro.

the used 1x configuration will be addressed in 2743.cfg on
icinga-core.git, with all future additions.

refs #2743

ConfigConvert: *interval, max_check_attempts dumped as numbers

see
https://git.icinga.org/?p=icinga2.git;a=blob_plain;f=lib/icinga/icinga-type.conf;hb=HEAD

refs #2743

ConfigConvert: fix undocumented contact templates conversion

refs #2743

s/DumpIcinga2Cfg/ExportIcinga2Cfg/g

just for Import/Export clarification.

configconvert: use special prefix for internal attributes

__I2CONVERT_ should do the trick, not to interfere with existing custom
variables.

configconvert: fix leftover from rename

configconvert: properly escape strings with double quotes

* command_line and command_args
* notification commands
* action_url, notes_url
* notes
* icon_image, icon_image_alt

fixes #3931

configconvert: fix multiple templates usage, template object lookup error

multiple host/service templates seperated by commas will cause some
irritation, therefore this is treated as array internally, like group
members. for the config export and "inherits", this is easy to fix. for
the actual host_name lookup for service objects, this unveiled another
bug when looping through all available templates - they are unique by
'name' and not by hostname/servicedesc, and require their very own
getter - obj_get_tmpl_obj_by_tmpl_name() - which makes sure to return
the object which is then looked into recursively if there's a host_name
provided.

possible bug for now - multiple service templates used and the host_name is
defined in one of them. but that's not the usual case, and won't be
supported for now.

refs #2743
fixes #3932

configconvert: dump modular timperiod attr and values

we need to ignore all other attributes which are to be cleaned sooner,
just for safety.

minor flaw: the keys are not sorted by weekdays now, but dumped like the
hash provides them.

fixes #4013

configconvert: support 'name' for groups' if *group_name is not set

this is a fallback for broken configs only, and since i got some, added
a small fix.

refs #2743

configconvert: add service->hostgroup<-hostmembers conversion to template support

WIP: there's multiple service->hostgroup relations - duplicated hosthg
templates. must be fixed.

refs #2743
refs #4016

configconvert: refactor service-hg-hosts for one hosthg template and multiple services

we need to first loop over all services, getting the key ids, collecting
them for each hostgroup_name (this is the unique identifier, because
this is our hosthg template later on).

then we loop over the collected unique hostgroups and build the 2.x
template logic. the difference here is now, that the code is refactored,
and loops over the service keys (getting their objects) only once,
pushing their templates plus a relation to a single (1) hosthg-template.

there's still some space for enhancements - the service template names
as well as hosthg template names as well as service object names are
generated with some hardcoded strings/numbers.

refs #2743
refs #4016

configconversion: remove debug output

configconvert: only dump macros if there are key-val pairs

configconvert: code cleanup

configconversion: explicitely check __I2CONVERT_USES_TEMPLATE == 1 when dumping service templates

refs #4020

configconvert: refactor how services without host_name are handled

this is mainly the cause when using hostgroup relations, or other object
tricks. we still need the single loop run to convert all 2.x object
attributes in one run, and deal with the missing attributes later on.

configconvert: WIP notification conversion

- refactored notification_commands parsing and storage
- do not add duplicated notification_command names to the 2x
  notification object hive
- create notifications based on the notification command linked from
  users
- move host->service link magic to the end again

refs #4008

configconvert: WIP notifications, how service/hosts relate to users and notifications

there may be more than one notification for the user, and we already had
the type in place. currently, that type is not taken into account (bug
to fix).

the rest with service -> user -> notification linking works in the first
implementation.

refs #4008

configconvert: final stage, rework notification type handling, fix naming amd template output

the config dump must take care of which notification type is dumped,
otherwise there would be yet another look required. Instead we are just
passing a reference from users to hosts/services with all prepared
notification attributes, and check them lazy on dump then.

further fixe on the notification names - they are not unique by their
command (now used on host/service scope, not user/contact) so we'll add
some magic number as suffix.

fixed template name dumping due to changed conversion vars too.

refs #4008

configconvert: write config files, refactor how objects are exported

structure is currently hardcoded, but may be changed to getopts later
on. all files are overridden into conf/ (testing only right on).

refactored export code, removed everything from Convert.pm, and export
is now called from the script directly, wrapped all dump loops and added
more function layers in betweed. open/close file handles take care of
everything, next to a header on top of the files for getting to know
their origin better (our hard work, ey?).

refs #4036

configconvert: fix service description handling, it's now an inner conversion value

previously, i've just re-used 'service_description' which isn't a valid
2.x attribute either. the lookup of service_description attribute in 1.x
templates works already, but populated __I2CONVERT_SERVICEDESCRIPTION
instead. in favor of having a generated value for all our objects, we'll
use that one, also for dumping the configuration.

even further, this is also changed for the service->hostgroup<-hosts
conversion then.

this also avoids writing empty service names into host->service objects.

fixes #4019

configconvert: add small main config file for standalone tests

refs #2743

configconvert: s/usergroups/groups/ for User config dump

configconvert: add README

configconvert: add ITL templates automatically (for services, notifications)

this currently only makes sense for services and notifications.

refs #4037

configconvert: fix timeperiod ranges, add template support for ITL inherits

refs #4037
refs #4013

configconvert: update requirements, perl deps

refs #2743

configconvert: fix import parser - timeperiods require regex (thx LConfImport)

somehow, the Icinga2 import still fails with us holiday definitions. bug
that's not yet determined whose bug that is.

refs #4039
refs #4013

configconvert: add getopts and pod2usage incl help

fixes #4041

configconvert: add notification_interval|period

and refactor check|retry_interval vs normal|retry_check_interval

refs #4008

configconvert: make host->service linked service a template object, referenced by the host

this is not the best solution, as it it creates a service template for
each host-service relation. if you have many host_name entries defined
in your Icinga 1.x config for a service, this will create duplicates
then. requires some more code refactoring, therefore leaving the issue
open.

refs #3933

configconvert: drop config file prefix 'icinga2'

just makes it hard to work with.

refs #4036

configconvert: code cleanup

configconvert: export check_period for hosts/services

refs #2743

configconvert: WIP dependencies - for host based on host_name and parents

refs #4011

configconvert: s/Timeperiod/TimePeriod/g

refs #4013

configconvert: add hostdependency with hostgroup_name hosts unrolling

refs #4011

configconvert: add servicedependency support (host_name)

missing - the loop fun with hostgroups.

special config is here:
https://git.icinga.org/?p=icinga-core.git;a=blob;f=tests/etc/2743.cfg;hb=refs/heads/next#l376

refs #4011

configconvert: add service dependency support for hostgroups

well, a lot of looping required here:

- loop through all child hostgroup hosts and get their hostnames
- get the servive object based on each hostname (loop again) and
  the child service description
- loop through all master hostgroup hosts and get their hostnames
- get the master hostname based on each hostname (loop again) and
  the master service description, save that as service dependency

given that implementation, dependencies may be converted for now.

once we decide which options we support, we may add them as well.

refs #4011

configconvert: add support for * as service host_name next to comma seperated list

this is currently a proof of concept for services only, but should
target all the object tricks later on. this will be done on host_name
lookup and stored as array.

http://docs.icinga.org/latest/en/objecttricks.html

refs #4010

configconvert: refactor commaseperated list split

... to list of stripped strings into a function.

fixes #4046

configconvert: handle excluded hosts, ignore them on split to array

exclusions/exceptions cannot be treated by icinga2 the same way as in
1.x so it's better to not create unwanted objects.

fixes #4007

configconvert: replace colon in object names with underscore

it's a special delimiter and therefore forbidden.

fixes #4225

configconvert: detect additive inheritance for *groups and use += on export

i guess this can be used for host/service contact(groups) and other foo
as well, so let's see.

refs #4006

configconvert: add wildcard detection for 'members *' in hostgroup

currently adds itself to the host's hostgroups array, but maybe a global
template where all hosts inherit from, plus additive inheritance fit
better here.

refs #4010

configconvert: add a note about servicedeps wildcards todo

refs #4010

configconvert: svg-hg-hst logic may contain multiple hgnames for services

the object tricks section on the 1.x documentation contains everything
which makes the code less readable even here.

luckily the code is rather modular, so the extension for split string to
array, and looping doesn't hurt much.

refs #4010

configconvert: update README with usage and todos

refs #2743

configconvert: fix perl 5.14, skip non-existing objects

configconvert: escape display_name (may contain quotes)

refs #3931

configconvert: refactor using command objects (check/notification)

eventhandlers are missing.

fixes #4305

configconvert: add volatile attribute

fixes #4321

configconvert: eventhandler as EventCommand objects

fixes #4327

update TODOs

configconvert: remove obsolete itl notification template

and check if defined when used.

refs #2743

configconvert: write compat log too in icinga2 conf

Revert "itl: fix inclusion of notification.conf"

This reverts commit 02eb54dc1a818fdcafa6c85817e9f6341cf2831a.

configconvert: fix thinko with check_command|event_command in service

refs #2743
refs #4327
refs #4305

11 years agoFix: Timeperiods: legacy-timeperiod parsed empty, results in skipped checks
Gunnar Beutner [Mon, 24 Jun 2013 13:01:23 +0000 (15:01 +0200)]
Fix: Timeperiods: legacy-timeperiod parsed empty, results in skipped checks

Fixes #4336

11 years agostatus.dat: Escape new-lines in multi-line plugin output
Gunnar Beutner [Mon, 24 Jun 2013 09:35:56 +0000 (11:35 +0200)]
status.dat: Escape new-lines in multi-line plugin output

Fixes #3671

11 years agoFix: missing check_command attribute results in sigsegv on check execution
Gunnar Beutner [Mon, 24 Jun 2013 07:30:49 +0000 (09:30 +0200)]
Fix: missing check_command attribute results in sigsegv on check execution

Fixes #4331

11 years agoRemove obsolete templates.
Gunnar Beutner [Mon, 24 Jun 2013 07:24:33 +0000 (09:24 +0200)]
Remove obsolete templates.

11 years agoFix: Compat Log: abort on OwnLock()
Gunnar Beutner [Mon, 24 Jun 2013 06:56:13 +0000 (08:56 +0200)]
Fix: Compat Log: abort on OwnLock()

Fixes #4332

11 years agodocs: s/check_command/command/ on command object, s/CGIs/Classic UI/
Michael Friedrich [Sat, 22 Jun 2013 10:51:43 +0000 (12:51 +0200)]
docs: s/check_command/command/ on command object, s/CGIs/Classic UI/

"CGIs" is an old definition, it's now referenced as "Classic UI" within
the icinga eco system.

11 years agoUpdate the flapping detecting formula.
Gunnar Beutner [Fri, 21 Jun 2013 10:51:29 +0000 (12:51 +0200)]
Update the flapping detecting formula.

11 years agoImplement external commands for flapping detection.
Gunnar Beutner [Fri, 21 Jun 2013 08:28:21 +0000 (10:28 +0200)]
Implement external commands for flapping detection.

11 years agoImplement flapping detection.
Gunnar Beutner [Fri, 21 Jun 2013 08:20:29 +0000 (10:20 +0200)]
Implement flapping detection.

11 years agoConfig: Fix nested dictionaries in arrays.
Gunnar Beutner [Fri, 21 Jun 2013 07:07:57 +0000 (09:07 +0200)]
Config: Fix nested dictionaries in arrays.

11 years agoMake error message more user-friendly.
Gunnar Beutner [Fri, 21 Jun 2013 07:03:02 +0000 (09:03 +0200)]
Make error message more user-friendly.

11 years agoAdd missing lock.
Gunnar Beutner [Fri, 21 Jun 2013 06:30:26 +0000 (08:30 +0200)]
Add missing lock.

11 years agoBugfix for removing expired downtimes.
Gunnar Beutner [Wed, 19 Jun 2013 12:28:46 +0000 (14:28 +0200)]
Bugfix for removing expired downtimes.

11 years agoImplement support for acknowledgement comments.
Gunnar Beutner [Wed, 19 Jun 2013 08:57:07 +0000 (10:57 +0200)]
Implement support for acknowledgement comments.

Fixes #3585

11 years agoImplement support for downtime comments.
Gunnar Beutner [Wed, 19 Jun 2013 08:42:28 +0000 (10:42 +0200)]
Implement support for downtime comments.

Fixes #3894

11 years agoDon't seal DynamicObject updates.
Gunnar Beutner [Wed, 19 Jun 2013 08:37:50 +0000 (10:37 +0200)]
Don't seal DynamicObject updates.

11 years agoRemove unused typedef.
Gunnar Beutner [Wed, 19 Jun 2013 08:19:04 +0000 (10:19 +0200)]
Remove unused typedef.

11 years agoUpdate tutorial.
Gunnar Beutner [Mon, 17 Jun 2013 07:39:06 +0000 (09:39 +0200)]
Update tutorial.

11 years agoRemoved obsolete file.
Gunnar Beutner [Mon, 17 Jun 2013 07:38:18 +0000 (09:38 +0200)]
Removed obsolete file.

11 years agoImplement volatile services
Gunnar Beutner [Thu, 13 Jun 2013 10:24:20 +0000 (12:24 +0200)]
Implement volatile services

Fixes #3593

11 years agoImplement command timeouts.
Gunnar Beutner [Thu, 13 Jun 2013 10:05:24 +0000 (12:05 +0200)]
Implement command timeouts.

Fixes #2723

11 years agoRefactor commands and implement event handlers.
Gunnar Beutner [Thu, 13 Jun 2013 09:33:00 +0000 (11:33 +0200)]
Refactor commands and implement event handlers.

Fixes #3877
Fixes #4001

11 years agoRemove the ILogger interface.
Gunnar Beutner [Thu, 6 Jun 2013 09:26:30 +0000 (11:26 +0200)]
Remove the ILogger interface.

Fixes #3860

11 years agoFix inheritance for config types.
Gunnar Beutner [Thu, 6 Jun 2013 09:26:00 +0000 (11:26 +0200)]
Fix inheritance for config types.

11 years agoFix dependency problem for "make dist".
Gunnar Beutner [Thu, 6 Jun 2013 08:16:28 +0000 (10:16 +0200)]
Fix dependency problem for "make dist".

Fixes #4200

11 years agoWindows build fix.
Gunnar Beutner [Tue, 4 Jun 2013 08:13:32 +0000 (10:13 +0200)]
Windows build fix.

11 years agoRename 'path_prefix' option to 'perfdata_path'.
Gunnar Beutner [Tue, 4 Jun 2013 07:52:37 +0000 (09:52 +0200)]
Rename 'path_prefix' option to 'perfdata_path'.

11 years agoFixed grammar mistake.
Gunnar Beutner [Wed, 15 May 2013 09:11:21 +0000 (11:11 +0200)]
Fixed grammar mistake.

11 years agoUpdate CGI section in the tutorial.
Gunnar Beutner [Wed, 15 May 2013 09:07:19 +0000 (11:07 +0200)]
Update CGI section in the tutorial.

Fixes #4161

11 years agoImplement notification escalations.
Gunnar Beutner [Mon, 13 May 2013 11:44:57 +0000 (13:44 +0200)]
Implement notification escalations.

11 years agoFix ThreadPool exception on shutdown.
Gunnar Beutner [Mon, 13 May 2013 07:58:24 +0000 (09:58 +0200)]
Fix ThreadPool exception on shutdown.

Fixes #3891

11 years agoFix infinite loop in LegacyTimePeriod::FindNthWeekday().
Gunnar Beutner [Wed, 8 May 2013 10:48:45 +0000 (12:48 +0200)]
Fix infinite loop in LegacyTimePeriod::FindNthWeekday().

11 years agoMake error message about invalid object names more verbose.
Gunnar Beutner [Wed, 8 May 2013 08:50:56 +0000 (10:50 +0200)]
Make error message about invalid object names more verbose.

11 years agoFix: ConfigItem types and names are not case-insensitive
Gunnar Beutner [Wed, 8 May 2013 08:46:50 +0000 (10:46 +0200)]
Fix: ConfigItem types and names are not case-insensitive

Fixes #4044

11 years agoDisallow colons in user-defined objects. Use colons for auto-generated object names.
Gunnar Beutner [Tue, 7 May 2013 07:22:39 +0000 (09:22 +0200)]
Disallow colons in user-defined objects. Use colons for auto-generated object names.

11 years agoDon't allow config items to inherit from themselves.
Gunnar Beutner [Tue, 7 May 2013 07:14:23 +0000 (09:14 +0200)]
Don't allow config items to inherit from themselves.

Fixes #4045

11 years agoRename .txt files to .adoc.
Gunnar Beutner [Mon, 6 May 2013 10:07:46 +0000 (12:07 +0200)]
Rename .txt files to .adoc.

11 years agoicinga2.spec: show some love for proper builds
Michael Friedrich [Sat, 4 May 2013 15:49:28 +0000 (17:49 +0200)]
icinga2.spec: show some love for proper builds

- icinga2 binary location changed to sbin/
- new initscript
- itl is installed into share/
- man pages in man/
- use name macro for every 'icinga2' occurence
- add a changelog

update to 0.0.2 release

fixes #4050

11 years agoFix type name.
Gunnar Beutner [Fri, 3 May 2013 13:43:15 +0000 (15:43 +0200)]
Fix type name.

11 years agoInit script: Fix shell redirection.
Gunnar Beutner [Fri, 3 May 2013 12:49:21 +0000 (14:49 +0200)]
Init script: Fix shell redirection.

11 years agoImplement -d (daemonize) and -e (errorlog).
Gunnar Beutner [Fri, 3 May 2013 11:39:31 +0000 (13:39 +0200)]
Implement -d (daemonize) and -e (errorlog).

11 years agoFix uninitialized variables.
Gunnar Beutner [Fri, 3 May 2013 10:44:27 +0000 (12:44 +0200)]
Fix uninitialized variables.

11 years agoFix parsing <MONTH> <DAY> time defs (e.g. "december 25").
Gunnar Beutner [Fri, 3 May 2013 10:31:11 +0000 (12:31 +0200)]
Fix parsing <MONTH> <DAY> time defs (e.g. "december 25").

Fixes #4040

11 years agoFix DST bug in LegacyTimePeriod::ParseTimeSpec().
Gunnar Beutner [Fri, 3 May 2013 10:30:57 +0000 (12:30 +0200)]
Fix DST bug in LegacyTimePeriod::ParseTimeSpec().

11 years agoRemoved dependency on boost/uuid.
Gunnar Beutner [Fri, 3 May 2013 09:26:18 +0000 (11:26 +0200)]
Removed dependency on boost/uuid.

11 years agoAdd missing comma.
Gunnar Beutner [Fri, 3 May 2013 09:23:42 +0000 (11:23 +0200)]
Add missing comma.

11 years agoTutorial: Add section about time periods.
Gunnar Beutner [Fri, 3 May 2013 09:10:32 +0000 (11:10 +0200)]
Tutorial: Add section about time periods.

11 years agoImplement new validation type: name(Type)
Gunnar Beutner [Fri, 3 May 2013 08:48:28 +0000 (10:48 +0200)]
Implement new validation type: name(Type)

11 years agoITL: add 'legacy-timeperiod' with update method
Michael Friedrich [Thu, 2 May 2013 20:15:50 +0000 (22:15 +0200)]
ITL: add 'legacy-timeperiod' with update method

fixes #4038

11 years agoUpdate INSTALL file.
Gunnar Beutner [Thu, 2 May 2013 12:50:07 +0000 (14:50 +0200)]
Update INSTALL file.

11 years agoUpdate documentation.
Gunnar Beutner [Wed, 24 Apr 2013 12:15:08 +0000 (14:15 +0200)]
Update documentation.

11 years agoUpdate tutorial.
Gunnar Beutner [Wed, 24 Apr 2013 07:35:58 +0000 (09:35 +0200)]
Update tutorial.

11 years agoUpdate config syntax documentation. Add install/config tutorial.
Gunnar Beutner [Tue, 23 Apr 2013 13:24:35 +0000 (15:24 +0200)]
Update config syntax documentation. Add install/config tutorial.

11 years agoFix VPATH asciidoc builds.
Gunnar Beutner [Tue, 23 Apr 2013 10:35:06 +0000 (12:35 +0200)]
Fix VPATH asciidoc builds.

11 years agoBuild fix.
Gunnar Beutner [Mon, 22 Apr 2013 09:39:01 +0000 (11:39 +0200)]
Build fix.

11 years agoconfigure.ac: Fix Python detection.
Gunnar Beutner [Mon, 22 Apr 2013 09:31:15 +0000 (11:31 +0200)]
configure.ac: Fix Python detection.