Hello,
I’m working on migrating hosts from manual configuration files to the Director. Unfortunately I’ve had some issues related to endpoints - once I’ve removed the config for the hosts, WITHOUT removing the manual endpoint and zone definitions, everything seems to work OK.
However, as soon as I remove the endpoint and zone definitions
#object Endpoint "example.ac.uk" {
# host = "example.ac.uk"
# log_duration = 0
#}
I get errors like the following:
[2024-01-09 15:51:54 +0000] critical/config: Error: Validation failed for object ‘example.ac.uk!check_disk basic-partitions’ of type ‘Service’; Attribute ‘command_endpoint’: Object ‘example.ac.uk’ of type ‘Endpoint’ does not exist.
Location: in /var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf: 6:5-6:32
/var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf(4): retry_interval = 1m
/var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf(5): enable_active_checks = true
/var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf(6): command_endpoint = host_name
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf(7): }
/var/lib/icinga2/api/packages/director/48df68e1-eaf2-4623-9da2-411f0cb21374/zones.d/director-global/service_templates.conf(8):
This becomes a bit of a chicken-and-egg problem because I can’t reload Icinga via the Director or via the command line either - and it doesn’t seem like there’s a way to get the Director to automatically add these removed zones and endpoints.
- Director version (System - About): 1.11.0
- Icinga Web 2 version and modules (System - About): 2.12.1
- Icinga 2 version (
icinga2 --version
): r2.14.1-1 - Operating System and version: CentOS 7
- Webserver, PHP versions: 7.3.33