Hi all,
i’m a new user of Icinga2 and i’m trying to migrate from Xymon (BigBrother) to Icinga2. In the first step, i set up an Icinga2 Instance with icingaweb2 and icinga-director.
Setup steps:
- installiing icinga2
- running icinga2 node wizard
- installing Icinga Director
- starting the kickstart wizard
- installing some other modules
The Webfrontend seems to be okay, i can change settings and deploy them, but if i try to add the master node into icinga and deploy the changes, icinga director returns an error:
[2022-04-05 08:56:57 +0200] information/cli: Icinga application loader (version: 2.13.2-1)
[2022-04-05 08:56:57 +0200] information/cli: Loading configuration file(s).
[2022-04-05 08:56:57 +0200] critical/config: Error: Object 'master.example.com' of type 'Endpoint' re-defined: in [stage]/zones.d/master/agent_endpoints.conf: 1:0-1:48; previous definition: in /etc/icinga2/zones.conf: 6:1-6:49
Location: in [stage]/zones.d/master/agent_endpoints.conf: 1:0-1:48
[stage]/zones.d/master/agent_endpoints.conf(1): object Endpoint "master.example.com" {
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[stage]/zones.d/master/agent_endpoints.conf(2): host = "master.example.com"
[stage]/zones.d/master/agent_endpoints.conf(3): log_duration = 0s
[2022-04-05 08:56:57 +0200] critical/cli: Config validation failed. Re-run with 'icinga2 daemon -C' after fixing the config.
Output of the icinga2 node wizard
icinga2 node wizard
Welcome to the Icinga 2 Setup Wizard!
We will guide you through all required configuration details.
Please specify if this is an agent/satellite setup ('n' installs a master setup) [Y/n]: n
Starting the Master setup routine...
Please specify the common name (CN) [master.example.com]:
Reconfiguring Icinga...
Checking for existing certificates for common name 'master.example.com'...
Certificates not yet generated. Running 'api setup' now.
Generating master configuration for Icinga 2.
Enabling feature api. Make sure to restart Icinga 2 for these changes to take effect.
Master zone name [master]:
Default global zones: global-templates director-global
Do you want to specify additional global zones? [y/N]:
Please specify the API bind host/port (optional):
Bind Host []:
Bind Port []:
Do you want to disable the inclusion of the conf.d directory [Y/n]:
Disabling the inclusion of the conf.d directory...
Checking if the api-users.conf file exists...
Done.
Now restart your Icinga 2 daemon to finish the installation!
Content of /etc/icinga2/zones.conf
/*
* Generated by Icinga 2 node setup commands
* on 2022-04-04 14:05:18 +0200
*/
object Endpoint "master.example.com" {
}
object Zone "master" {
endpoints = [ "master.example.com" ]
}
object Zone "global-templates" {
global = true
}
object Zone "director-global" {
global = true
}
I hope, this information are enough. Details of my installation:
Output of icinga --version
icinga2 --version
icinga2 - The Icinga 2 network monitoring daemon (version: 2.13.2-1)
Copyright (c) 2012-2022 Icinga GmbH (https://icinga.com/)
License GPLv2+: GNU GPL version 2 or later <https://gnu.org/licenses/gpl2.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
System information:
Platform: CentOS Linux
Platform version: 7 (Core)
Kernel: Linux
Kernel version: 3.10.0-1160.59.1.el7.x86_64
Architecture: x86_64
Build information:
Compiler: GNU 4.8.5
Build host: runner-hh8q3bz2-project-322-concurrent-0
OpenSSL version: OpenSSL 1.0.2k-fips 26 Jan 2017
Application information:
General paths:
Config directory: /etc/icinga2
Data directory: /var/lib/icinga2
Log directory: /var/log/icinga2
Cache directory: /var/cache/icinga2
Spool directory: /var/spool/icinga2
Run directory: /run/icinga2
Old paths (deprecated):
Installation root: /usr
Sysconf directory: /etc
Run directory (base): /run
Local state directory: /var
Internal paths:
Package data directory: /usr/share/icinga2
State path: /var/lib/icinga2/icinga2.state
Modified attributes path: /var/lib/icinga2/modified-attributes.conf
Objects path: /var/cache/icinga2/icinga2.debug
Vars path: /var/cache/icinga2/icinga2.vars
PID path: /run/icinga2/icinga2.pid
icinga2 feature list
Disabled features: compatlog debuglog elasticsearch gelf icingadb influxdb influxdb2 livestatus opentsdb perfdata statusdata
Enabled features: api checker command graphite ido-mysql mainlog notification syslog
Maybe it’s just a simple configuration error.
Regards,
Stephan