At first I filled out the form for SERVER23, then clicked on save. It was more of a guess which field to fill and what to put in them. Then I clicked on Clone and filled in some information for SERVER9 and clicked on save. I totally messed up. I cannot tell you exactly which fields I put data into, but I’m pretty sure the ‘parent’ field was wrong too
For your second question: In order to delete SERVER9.local I first have to click on the server. But then this appears instead:
It just created another log entry on top of the stack. Then I click on Deploy changes but it always gets stuck at the third entry from the bottom. I can create as many changes as I want. As long as the log entry [kamikater] modify host "SERVER9.local" is still there, I won’t make any progress.
I have to fix this today. Maybe I can delete the entry via ssh?
the problem is somewhere in the inheritance chain of an object, you can dump / backup the director database and remove the object that causes the issue.
can you execute that on the director database:
SELECT * FROM `icinga_host_inheritance` where `parent_host_id`=1382;
Yes, that shows me exactly one entry. But there are only two columns with both 1382 as value. I will not just simply delete the entry, there are probably some constraints. It would make things even worse.
if the first query has the same value in both colums you have to delete this row, because it references the host to import the host itself which causes the issue.
after that you can delete the host in icinga director.
if you want to keep the host you have to add a new template under imports!
If host_id and parent_host_id are the same, that has to be the issue, as you said.
The output of SELECT * FROM `icinga_host_inheritance` where `parent_host_id`=1382; is too big to post it directly here, so I will post the most interesting fields of the single result: