All hosts except for those with agents in 'pending' state

We monitor about 56 different hosts, and they’re all for some reason in ‘pending’ state as of last week.

The only hosts that are returning results are the two we have, which have separate agents setup.

I’m not sure what’s changed, and I don’t see an error that is pointing me in the right direction.

Any advice at all would be very much appreciated.

Can you explain “the two we have, which have separate agents setup” a bit
more?

What’s the configuration of those two, and what’s the configuration of the other
54?

Also, can you confirm that you’re talking about the Hosts Check here, and not
any of the Service Checks?

Which check are you using for Host Up/Down/Unknown?

Antony.

It’s actually the host checks and the services checks both – if i go to hosts, everything is pending. if i go to services, everything is pending.

The two that are working, are remote agents - all the other hosts i’m monitoring do not have agents attached. These have also all worked up until yesterday.

So, two questions:

  1. Do you have a network connection between the two agents and the master
    Icinga server? Do the log files at either end tell you anything about not
    being able to connect?

  2. If you have 54 machines which you’re monitoring without agents installed,
    how are you performing the service checks on them?

Antony.

  1. Yes
  2. With remote checks.

Found out the issue - constants.conf was updated somehow (“icinga2 api setup” possibly) and the constants.conf file’s zonename was updated to our server’s hostname.

  1. So all of our hosts disappeared.
  2. We first, intuitively, and erroneously updated the zones.conf file to have ‘master’ zone in it (with correct syntax), and all the hosts showed up in pending state.
  3. We removed that zones.conf adjustment, and changed the zones.d/‘masters’ folder to zones.d/‘hostname’ and it all worked.