0

I just setup Check_MK (so Nagios and OMD as well) on a new CentOS 7 server, and I'm pretty sure everything's setup fine. I created a new check_mk "site" via OMD (called staging). I logged into another server and installed the check_mk_agent, then I went to the staging site and added the host, and selected Check_MK Agent. When I clicked Save & Go To Services, I was able to see everything that was being checked via the Check_MK agent, so it looked like it got setup just fine.

However, when I click on the All Hosts* item under the **Views menu, I don't see the host. And when I try to inventory the host that I'm monitoring, I get an error saying it doesn't match any host..

# cmk -I silo-stg-a01
Hostname or tag specification 'silo-stg-a01' does not match any host.
# cmk -I silo-stg-a01.company.com
Hostname or tag specification 'silo-stg-a01.company.com' does not match any host.
# cmk -I 192.168.1.34
Hostname or tag specification '192.168.1.34' does not match any host.

However, I can view the raw information just fine

# check_mk -d 192.168.1.34 | head
<<<check_mk>>>
Version: 1.2.6p16
AgentOS: linux
AgentDirectory: /etc/check-mk-agent
DataDirectory: /var/lib/check_mk_agent
SpoolDirectory: /var/lib/check_mk_agent/spool
PluginsDirectory: /usr/share/check-mk-agent/plugins
LocalDirectory: /usr/share/check-mk-agent/local
OnlyFrom:
<<<df>>>

Can someone tell me what I'm doing wrong? It looks like I may have missed a step, but not sure where.

Update

I just noticed that I had to review and accept the changes, once I did that, I was able to see the server under the All Hosts view, but I still cant inventory it via cmk..

codeforester
  • 39,467
  • 16
  • 112
  • 140
Justin
  • 1,959
  • 5
  • 22
  • 40

1 Answers1

0

I have seen the 'Hostname or tag specification ... does not match any host' error happening whenever we attempt to inventory a host that is not present in ipaddr.mk file. Here is how it works:

  1. Add the new host to /etc/check_mk/conf.d/ipaddr.mk file
  2. Create /etc/check_mk/conf.d/host_first_index.mk file.
  3. Run cmk -I _your_host_name_

I don't use the UI to manage adding/removing hosts, and hence I am not able to answer your question perfectly. Hope this helps.

codeforester
  • 39,467
  • 16
  • 112
  • 140