It seems to partially work. I have a service check file containing 3 checks [DNS related]. I ran the import and only one of the three got duplicated. Previously all three would have been duplicated. I removed the duplicate, and re-ran, and same issue.
define service {
use sv-service
hostgroup_name dns
service_description DNS: Bind DNS Throughput
check_command check_nrpe!check_bind_stats!!!!!!!!
parents alive
}
define service {
use sv-service
hostgroup_name dns
service_description DNS: xxxom.com lookup
check_command check_dns!axxx.xxxom.com
parents alive
}
define service {
use sv-service
hostgroup_name dns
service_description DNS: Processes - NameD
check_command check_nrpe!check_named_procs!!!!!!!
parents alive
}
As you can see the checks are pretty identical. However only the Bind Throughput is duplicating? Is my issue supposed to be fully resolved?
My systems started at 5.4 I think, but I have been upgrading them as new releases come out, usually within a few days [environment is not live yet, so I can get away with it]. So currently running 5.5.8
I swapped entry one and entry two in the CFG import and it still only duplicated the same one. My configs are split into services, so I just tried another config and it did not duplicate at all.
I am going to take a VM snapshot and import everything and see how it goes. Do you want the System Profile from that? Probably more data in there for you to look at.
I did a re-import and duplicated about 12 checks [out of ~200]. A little further investigation:
1. Bind check. My live system has a !host in there that was manually added.
2. Elasticsearch. Duplicated as the live version has 2 hostgroups instead of 1.
Working on these assumptions I have a feeling that the config import is now working, but due to deploying piecemeal there has been inconsistencies. Which is probable. I will revert in a bit after checking the other checks.
As a side note, is there an easy way from the CLI that I can check the Service names looking for a duplicate, so this can be added to my ansible plays?
Ah ok - i thought I might have to look in a DB or something.
Anyways, I have narrowed the duplicating checks to 2 checks. I am only back from a days leave so will have a look at those two this evening. Hopefully we can then close it off.