API Query to find Director node

This forum was archived to /woltlab and is now in read-only mode.
  • Hi

    Is it possible to find out on which icinga2 node is Director module running in a distributed monitoring Environment using Icinga2 API?

    I have several nodes in my master zone and one of them runs Director to generate and distribute the configs for all the nodes. I would like to find out from an external script, that makes Icinga2 API calls, which node runs Director.

    I know, that I could make MySQL queries or SSH connections to each node, and check whether the DB for the Director is there or if there are config files for Director, but I would prefer icinga2 API calls.

    Is it possible?


  • not directly, what you could do, is use the API to run a shell command as the nagios user to check if the director module is enabled.

    Linux is dead, long live Linux

    Remember to NEVER EVER use git repositories in a productive environment if you CAN NOT control them

  • Thanks!

    Which API call shall I use? Is it the Icinga2 Console? I haven't found any relevant tipps in the Icinga2 API docu.