Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dev.icinga.com #11740] .conf file will remain in apifolder if the zonesfolder in zones.d is removed or the last .conf-file is removed from /zones.d/zonefolder. #4191

Closed
icinga-migration opened this issue May 8, 2016 · 7 comments · Fixed by #6727
Assignees
Labels
area/distributed Distributed monitoring (master, satellites, clients) bug Something isn't working

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/11740

Created by rafael.voss on 2016-05-08 09:47:14 +00:00

Assignee: (none)
Status: New
Target Version: (none)
Last Update: 2016-11-18 14:08:56 +00:00 (in Redmine)

Icinga Version: 2.4.7
Backport?: Not yet backported
Include in Changelog: 1

As long there is more than one conf file in the zonefolder there is no problem, but if there is only one .conf-file in a zonefolder in /etc/icinga2/zones.d and this file is deleted (folder is empty now), the .conf-file will remain in the api folder in /var/lib/icinga2/api/zones/.

I have the same problem when i delete the entire zonefolder in zones.d.

i use the debmon packages on Debian Jessi.

As a workaround i have placed a dummy.conf with no content in the zonefolder.


Relations:

@icinga-migration
Copy link
Author

Updated by rafael.voss on 2016-07-08 07:41:49 +00:00

To recreate this bug:

  1. Create a new zone,endpoint
  2. mkdir etc/icinga2/zones.d/zonename
  3. copy a working .conf file into etc/icinga2/zones.d/zonename/
  4. reload icinga
  5. remove the conf file
  6. reload icinga

the conf file will remain in /var/lib/icinga2/api/zones/zonename/_etc/filename.conf

The problem: the master will not use this file in configchecks as its not in zones.d anymore, but it will transfer this file to the zones. As result the zone executes the checks, but you will not find these checks in your configs on the master. And finally its possible to create new checks with same names somewhere else without hitting a config error.

If you follow the steps again, but create/copy 2 .conf files into the zonename directory all will work as expected.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2016-11-18 14:08:48 +00:00

  • Relates set to 10000

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2016-11-18 14:08:56 +00:00

  • Category set to Cluster

@icinga-migration icinga-migration added bug Something isn't working area/distributed Distributed monitoring (master, satellites, clients) labels Jan 17, 2017
@NeverUsedID
Copy link

Looks like this bug still exists in 2.8.0

Just moved the last .conf file from one global zone to another. ALL Icinga2 agents failed to reload, because now the command "is predefined" in both zones. To solve this, a simple "touch dummy.conf" in the "empty" old zone at the master, followed by a reload solved the problem.

@Al2Klimov
Copy link
Member

@NeverUsedID What about v2.10.2?

@Al2Klimov Al2Klimov pinned this issue Mar 11, 2019
@Al2Klimov Al2Klimov unpinned this issue Mar 11, 2019
@Al2Klimov Al2Klimov self-assigned this Mar 11, 2019
@Al2Klimov Al2Klimov added the needs feedback We'll only proceed once we hear from you again label Mar 11, 2019
@dnsmichi
Copy link
Contributor

I will deal with this as part of #6716.

@dnsmichi dnsmichi assigned dnsmichi and unassigned Al2Klimov Mar 12, 2019
@dnsmichi dnsmichi removed the needs feedback We'll only proceed once we hear from you again label Mar 12, 2019
@dnsmichi dnsmichi added this to the 2.11.0 milestone Mar 19, 2019
@dnsmichi
Copy link
Contributor

dnsmichi commented Jun 6, 2019

I'm closing this in favor of #6716.

@dnsmichi dnsmichi closed this as completed Jun 6, 2019
@dnsmichi dnsmichi removed this from the 2.11.0 milestone Jun 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/distributed Distributed monitoring (master, satellites, clients) bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants