Sunday, April 16, 2017

Re: @sample in net/icinga/core

On 2017/04/16 10:45, Florian Obser wrote:
> Hi,
>
> so the icinga port @samples quite a few config files for
> /etc/icinga/object/. Some of them are starting to get in the way.
>
> printer.cfg, switch.cfg, windows.cfg, localhost.cfg:
>
> I place all my hosts in a subdirectory "objects/hosts" and use
> obj_dir=/etc/icinga/objects, also I don't monitor a printer. I can
> delete those files, but they are put back on every update.
> I suspect I can just empty them. But then I have those files
> lying around.
>
> localhost.cfg is particularly anoying since I do have a host named
> localhost defined somewhere else which then leeds to icinga not
> starting after an upgrade because the object is defined twice.
>
> My knee jerk reaction is to stop @sample'ing those files, but maybe
> there is a better way to deal with this?
>
> Thanks,
> Florian
>
> --
> I'm not entirely sure you are real.

I see where you're coming from, there's a lot of junk in there, but
think it is quite useful to have a working default config after a pkg_add
and I don't see a different way to achieve that.

I just ignore the objects/ directory completely: copied what I wanted
to another directory and changed the cfg_file lines in icinga.cfg.

Otherwise leaving them as blank files would do the trick, as would
removing/commenting the relevant icinga.cfg lines.

No comments:

Post a Comment