<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-2022-jp">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p style="margin-top:0;margin-bottom:0">So you are using separate cluster-zone service check?</p>
<p style="margin-top:0;margin-bottom:0">What are you using for the host check?</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">Rick</p>
<br>
<br>
<div style="color: rgb(0, 0, 0);">
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> icinga-users <icinga-users-bounces@lists.icinga.org> on behalf of mustafa mujahid <mustafa.mujahid@outlook.com><br>
<b>Sent:</b> July 10, 2018 7:16 AM<br>
<b>To:</b> Icinga User's Corner<br>
<b>Subject:</b> Re: [icinga-users] Distributed Monitoring for Client Host cluster-zone command question</font>
<div> </div>
</div>
<meta content="text/html; charset=iso-2022-jp">
<div dir="ltr">
<meta name="x_Generator" content="Microsoft Word 15 (filtered medium)">
<style>
<!--
@font-face
        {font-family:"Cambria Math"}
@font-face
        {font-family:Calibri}
p.x_MsoNormal, li.x_MsoNormal, div.x_MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif}
a:x_link, span.x_MsoHyperlink
        {color:blue;
        text-decoration:underline}
a:x_visited, span.x_MsoHyperlinkFollowed
        {color:#954F72;
        text-decoration:underline}
pre
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New"}
span.x_HTMLPreformattedChar
        {font-family:"Courier New"}
.x_MsoChpDefault
        {}
@page WordSection1
        {margin:72.0pt 72.0pt 72.0pt 72.0pt}
div.x_WordSection1
        {}
-->
</style>
<div class="x_WordSection1">
<p class="x_MsoNormal">This is a valid question to which I was also looking for the answer. If the zone disconnects then only the cluster zone service fails. When it should trigger the RED for all services in that zone. It doesn’t happen. I guess dependency
 checks can be used but I’m not sure.</p>
<p class="x_MsoNormal"> </p>
<p class="x_MsoNormal">BR/Mustafa.</p>
<p class="x_MsoNormal"> </p>
<p class="x_MsoNormal">Sent from <a href="https://go.microsoft.com/fwlink/?LinkId=550986" id="LPlnk378088" class="OWAAutoLink" previewremoved="true">
Mail</a> for Windows 10</p>
<p class="x_MsoNormal"> </p>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> icinga-users <icinga-users-bounces@lists.icinga.org> on behalf of Rick Liu <totoroliu1215@hotmail.com><br>
<b>Sent:</b> Tuesday, July 10, 2018 4:05:56 AM<br>
<b>To:</b> icinga-users@lists.icinga.org<br>
<b>Subject:</b> [icinga-users] Distributed Monitoring for Client Host cluster-zone command question</font>
<div> </div>
</div>
<div>
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p style="margin-top:0; margin-bottom:0"><span style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">Hi,</span><br>
</p>
<div style="color:rgb(0,0,0)">
<div dir="ltr">
<div id="x_x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">I have setup a single master with 2 client endpoints in my icintga2 monitoring system using director</p>
<p style="margin-top:0; margin-bottom:0">with Top-Down mode. </p>
<p style="margin-top:0; margin-bottom:0">I have also setup 2 client nodes with both accept configs and accept commands.</p>
<p style="margin-top:0; margin-bottom:0">(hopefully this means I'm running <span><a href="https://www.icinga.com/docs/icinga2/latest/doc/06-distributed-monitoring/#top-down-command-endpoint" class="x_x_OWAAutoLink" id="LPlnk957418" previewremoved="true">Top
 Down Command Endpoint</a> mode)</span></p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">The service checks (disk/mem/load) for the 3 hosts are returning correct results.</p>
<p style="margin-top:0; margin-bottom:0">But my problem is:</p>
<p style="margin-top:0; margin-bottom:0">according to the example from <a href="https://www.icinga.com/docs/icinga2/latest/doc/06-distributed-monitoring/#top-down-command-endpoint" class="x_x_OWAAutoLink" id="LPlnk957418" style="font-family:Calibri,Helvetica,sans-serif,EmojiFont,"Apple Color Emoji","Segoe UI Emoji",NotoColorEmoji,"Segoe UI Symbol","Android Emoji",EmojiSymbols; font-size:16px" previewremoved="true">Top
 Down Command Endpoint</a> example,</p>
<p style="margin-top:0; margin-bottom:0">host icinga2-client1 is using "hostalive" as the host check_command.</p>
<p style="margin-top:0; margin-bottom:0">eg.</p>
<p style="margin-top:0; margin-bottom:0"></p>
<pre style="color:rgb(55,71,79); font-family:"Roboto Mono","Courier New",Courier,monospace; background-color:transparent; font-size:13.6px">object Host "icinga2-client1.localdomain" {
  check_command = "hostalive" //check is executed on the master
  address = "192.168.56.111"

  vars.client_endpoint = name //follows the convention that host name == endpoint name
}</pre>
But one issue I have is that 
<p></p>
<p style="margin-top:0; margin-bottom:0">if the client1 icinga process is not running,</p>
<p style="margin-top:0; margin-bottom:0">the host status stays green and also all of service status (disk/mem/load) stay all green as well</p>
<p style="margin-top:0; margin-bottom:0">because master is not getting any service check updates and hostalive is able to ping the node.</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">Under <a href="https://www.icinga.com/docs/icinga2/latest/doc/06-distributed-monitoring/#health-checks" class="x_x_OWAAutoLink" id="LPlnk886262" previewremoved="true">
Best Practice - Health Check</a> section,</p>
<p style="margin-top:0; margin-bottom:0">it mentioned to use "<span style="color:rgb(55,71,79); font-family:"Roboto Mono","Courier New",Courier,monospace; font-size:13.6px; background-color:rgba(237,237,237,0.5)">cluster-zone</span>" check commands.</p>
<p style="margin-top:0; margin-bottom:0">I was expecting while using "<span style="color:rgb(55,71,79); font-family:"Roboto Mono","Courier New",Courier,monospace; font-size:13.6px; background-color:rgba(237,237,237,0.5)">cluster-zone</span>",</p>
<p style="margin-top:0; margin-bottom:0">the host status would be RED when the client node icinga process is stopped,</p>
<p style="margin-top:0; margin-bottom:0">but somehow this is not happening.</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">Does anyone has any idea?</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">My zone/host/endpoint configurations are as follows:</p>
<p style="margin-top:0; margin-bottom:0"><span style="font-family:"Courier New",monospace; font-size:8pt"></span></p>
<div><br>
</div>
<div>object Zone "icinga-master" {<br>
    endpoints = [ "icinga-master" ]<br>
}</div>
<div><span style="font-size:8pt">object Host "icinga-master" {</span></div>
<p></p>
<p style="margin-top:0; margin-bottom:0"></p>
<pre style="overflow:auto; font-family:"Liberation Mono","Lucida Console",Courier,monospace; font-size:0.917em; margin-top:0px; margin-bottom:1em; background-image:none"><pre style="overflow:auto; font-family:"Liberation Mono","Lucida Console",Courier,monospace; font-size:0.917em; margin-top:0px; margin-bottom:1em; background-image:none"><span style="font-size:8pt; font-family:"Courier New",monospace">    import "Master-Template"

    display_name = "icinga-master [192.168.100.71]"
    address = "192.168.100.71"
    groups = [ "Servers" ]
}<div>object Endpoint "icinga-master" {<br>    host = "192.168.100.71"<br>    port = "5665"<br>}</div></span></pre><pre style="overflow:auto; font-family:"Liberation Mono","Lucida Console",Courier,monospace; font-size:0.917em; margin-top:0px; margin-bottom:1em; background-image:none"><div><span style="font-family:"Courier New",monospace; font-size:8pt">object Zone "rick-tftp" {</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    parent = "icinga-master"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    endpoints = [ "rick-tftp" ]</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">}</span></div><div><div><span style="font-family:"Courier New",monospace; font-size:8pt">object Endpoint "rick-tftp" {</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    host = "172.16.181.216"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">}</span></div><div><span style="font-family:"Courier New",monospace; font-size:8pt">object Host "rick-tftp" {</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    import "Host-Template"</span><br><br><span style="font-family:"Courier New",monospace; font-size:8pt">    display_name = "rick-tftp [172.16.181.216]"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    address = "172.16.181.216"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    groups = [ "Servers" ]</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    vars.cluster_zone = "icinga-master"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">}</span></div></div></pre><pre style="overflow:auto; font-family:"Liberation Mono","Lucida Console",Courier,monospace; font-size:0.917em; margin-top:0px; margin-bottom:1em; background-image:none"><div><span style="font-family:"Courier New",monospace; font-size:8pt">object Zone "tftp-server" {</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    parent = "icinga-master"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    endpoints = [ "tftp-server" ]</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">}</span></div><div><span style="font-family:"Courier New",monospace; font-size:8pt">object Endpoint "tftp-server" {</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">    host = "192.168.100.221"</span><br><span style="font-family:"Courier New",monospace; font-size:8pt">}</span></div><pre style="overflow:auto; font-family:"Liberation Mono","Lucida Console",Courier,monospace; font-size:0.917em; margin-top:0px; margin-bottom:1em; background-image:none"><span style="font-family:"Courier New",monospace; font-size:8pt">object Host "tftp-server" {
    import "Host-Template"

    display_name = "tftp-server [192.168.100.221]"
    address = "192.168.100.221"
    groups = [ "Servers" ]
    vars.cluster_zone = "icinga-master"
}</span></pre><br></pre></pre>
<p></p>
<p style="margin-top:0; margin-bottom:0">Thanks,</p>
<p style="margin-top:0; margin-bottom:0">Rick</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
</div>
<div id="x_x_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2"><br>
<table style="border-top:1px solid #D3D4DE">
<tbody>
<tr>
<td style="width:55px; padding-top:18px"><a href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail" target="_blank" id="LPlnk467742" class="x_OWAAutoLink" previewremoved="true"><img alt="" width="46" height="29" style="width: 46px; height: 29px; user-select: none;" src="https://ipmcdn.avast.com/images/icons/icon-envelope-tick-round-orange-animated-no-repeat-v1.gif"></a></td>
<td style="width:470px; padding-top:17px; color:#41424e; font-size:13px; font-family:Arial,Helvetica,sans-serif; line-height:18px">
不含病毒。<a href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail" target="_blank" id="LPlnk535243" class="x_OWAAutoLink" style="color:#4453ea" previewremoved="true">www.avast.com</a>
</td>
</tr>
</tbody>
</table>
<a href="#x_x_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2" width="1" height="1" id="LPlnk714011" class="x_OWAAutoLink" previewremoved="true"></a></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>