<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p>Hi <span>Siddhesh</span>.</p>
<p>the "url" parameter must have the interface IP address of each server, not the local loopback.</p>
<p>Kind regards<br>
</p>
<p><br>
</p>
<div id="Signature">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Helvetica, sans-serif, "EmojiFont", "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<b><img class="EmojiInsert" alt="1648137216676" src="cid:d5444d79-4475-4ee6-a4df-a1700abffcca"><br>
</b></div>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<b>Norberto Isaac Núñez</b>
<div><font size="2" face="Courier New, monospace"><span style="font-family:"Courier New",monospace; font-size:8pt">Ingeniería de servicios, Núcleo S.A.</span></font></div>
<span style="font-family:"Courier New",monospace; font-size:8pt"></span><font size="2"></font><span style="font-family:"Courier New",monospace; font-size:8pt"></span>
<div><font size="2" face="Courier New, monospace"><span style="font-family:"Courier New",monospace; font-size:8pt">Máximo Lira n° 522, Asunción.</span></font></div>
<span style="font-family:"Courier New",monospace; font-size:8pt"></span><font size="2"></font><span style="font-family:"Courier New",monospace; font-size:8pt"></span>
<div><font size="2" face="Courier New, monospace"><span style="font-family:"Courier New",monospace; font-size:8pt">Tel.:
</span><a href="tel:+595212199396" tabindex="0" id="LPNoLP" title="Ctrl+Haga clic o pulse para seguir el vínculo"><span style="font-family:"Courier New",monospace; font-size:8pt">+595212199396</span></a><span style="font-family:"Courier New",monospace; font-size:8pt">,
</span><a href="tel:+595971577190" tabindex="0" id="LPNoLP"><span style="font-family:"Courier New",monospace; font-size:8pt">+595971577190</span></a></font></div>
<span style="font-family:"Courier New",monospace; font-size:8pt"></span><font size="2"></font><span style="font-family:"Courier New",monospace; font-size:8pt"></span>
<div><font size="2" face="Courier New, monospace"><span style="font-family:"Courier New",monospace; font-size:8pt">eMail:
</span><a href="mailto:norberto.nunez@personal.com.py" tabindex="0" id="LPNoLP"><span style="font-family:"Courier New",monospace; font-size:8pt">Norberto.Nunez@personal.com.py</span></a></font></div>
<span style="font-family:"Courier New",monospace; font-size:8pt"></span><font size="2"></font><span style="font-family:"Courier New",monospace; font-size:8pt"></span>
<div><font size="2" face="Courier New, monospace"><span style="font-family:"Courier New",monospace; font-size:8pt">Web:
</span><a href="https://www.personal.com.py" tabindex="0" style="" id="LPNoLP"><span style="font-family:"Courier New",monospace; font-size:8pt">https://www.personal.com.py</span></a></font></div>
</div>
</div>
</div>
</div>
<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>De:</b> Kea-users <kea-users-bounces@lists.isc.org> en nombre de Siddhesh Dindorkar <siddhesh.p.d@gmail.com><br>
<b>Enviado:</b> lunes, 18 de julio de 2022 3:39:12<br>
<b>Para:</b> kea-users@lists.isc.org<br>
<b>Asunto:</b> [Kea-users] kea sync questions in hot-standby mode</font>
<div> </div>
</div>
<div>
<div dir="ltr">Hello,
<div><br>
</div>
<div>We are using <span class="gmail-il">kea</span> 1.8.2 in hot-standby mode. The problem I see is that if I onboard a new standby server, I don't see the <span class="gmail-il">kea</span> leases being synced to the standby. Any new lease that active server
 dishes out post onboarding the standby server is being synced, but not the existing ones that the active  server had. If I execute status-get on the dhcp4, I see that both the servers are in-touch. Not sure I am missing something basic. If I restart <span class="gmail-il">kea</span>-dhcp4
 service, then I see those leases getting synced to the standby server. Or if I explicitly execute the ha-sync command, then also I see the leases getting synced. There aren't any significant error messages in the <span class="gmail-il">kea</span> logs files
 as well, apart from the below ones:<br>
<br>
2022-07-18 07:01:50.452 DEBUG [<span class="gmail-il">kea</span>-dhcp4.http/2623.140619754313216] HTTP_BAD_SERVER_RESPONSE_RECEIVED bad response received when communicating with <a href="http://127.0.0.1:8001/" target="_blank">http://127.0.0.1:8001/</a>: unable
 to parse the body of the HTTP response: error: unexpected character u in <string>:1:2 : current state: [ 1 END_ST ] next event: [ 3 FAIL_EVT ]<br>
upstream connect error or disconnect/reset before headers. reset reason: connection failure<br>
2022-07-18 07:01:50.452 WARN  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/2623.140619754313216] HA_HEARTBEAT_COMMUNICATIONS_FAILED failed to send heartbeat to primary_server (<a href="http://127.0.0.1:8001/" target="_blank">http://127.0.0.1:8001/</a>):
 unable to parse the body of the HTTP response: error: unexpected character u in <string>:1:2 : current state: [ 1 END_ST ] next event: [ 3 FAIL_EVT ]<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>Difference in state changes between bringing up a new server vs restart of dhcp service:<br>
New server:<br>
2022-07-18 07:01:50.452 INFO  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/2623.140619754313216] HA_STATE_TRANSITION server transitions from WAITING to PARTNER-DOWN state, partner state is UNDEFINED<br>
2022-07-18 07:02:00.502 INFO  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/2623.140619754313216] HA_STATE_TRANSITION server transitions from PARTNER-DOWN to HOT-STANDBY state, partner state is READY<br>
<br>
</div>
<div>Restart of dhcp service:<br>
2022-07-18 06:57:06.105 INFO  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/1483.139947883714048] HA_STATE_TRANSITION server transitions from WAITING to SYNCING state, partner state is HOT-STANDBY<br>
2022-07-18 06:57:06.130 INFO  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/1483.139947883714048] HA_STATE_TRANSITION server transitions from SYNCING to READY state, partner state is HOT-STANDBY<br>
2022-07-18 06:57:06.130 INFO  [<span class="gmail-il">kea</span>-dhcp4.ha-hooks/1483.139947883714048] HA_STATE_TRANSITION server transitions from READY to HOT-STANDBY state, partner state is HOT-STANDBY<br>
</div>
<div><br>
</div>
<div><span class="gmail-il">kea</span> hooks configuration:<br>
"hooks-libraries": [<br>
        {<br>
            "library": "/usr/lib/<span class="gmail-il">kea</span>/hooks/libdhcp_lease_cmds.so",<br>
            "parameters": { }<br>
        },<br>
        {<br>
            "library": "/usr/lib/<span class="gmail-il">kea</span>/hooks/libdhcp_ha.so",<br>
            "parameters": {<br>
                "high-availability": [{<br>
                    "this-server-name":"standby_server",<br>
                    "mode": "hot-standby",<br>
                    "heartbeat-delay": 10000,<br>
                    "max-response-delay": 10000,<br>
                    "max-unacked-clients": 0,<br>
                    "peers": [<br>
                    {<br>
                       "name": "primary_server",<br>
                        "url": "<a href="http://127.0.0.1:8001/" target="_blank">http://127.0.0.1:8001/</a>",<br>
                        "role": "primary"<br>
                    },<br>
                    {<br>
                    "name": "standby_server",<br>
                    "url": "<a href="http://127.0.0.1:8001/" target="_blank">http://127.0.0.1:8001/</a>",<br>
                    "role": "standby"<br>
                    }]<br>
                }]<br>
            }<br>
        },<br>
        {<br>
        "library": "/usr/lib/<span class="gmail-il">kea</span>/hooks/libnsb_dhcp_hook.so",<br>
        "parameters": { }<br>
        },<br>
        {<br>
        "library": "/usr/lib/<span class="gmail-il">kea</span>/hooks/libdhcp_stat_cmds.so",<br>
        "parameters": { }<br>
        }<br>
        ],<br>
<br>
Please let me know if you need any additional logs / information. Thank you in advance for helping take a look into this.</div>
<div><br>
</div>
<div>Best,<br>
Siddhesh</div>
</div>
</div>
<br>
<hr>
<font face="Arial" color="Gray" size="1"><br>
AVISO LEGAL: Esta información es privada y confidencial y está dirigida únicamente a su destinatario. Si usted no es el destinatario original de este mensaje y por este medio pudo acceder a dicha información por favor elimine el mensaje. La distribución o copia
 de este mensaje está estrictamente prohibida. Esta comunicación es sólo para propósitos de información y no debe ser considerada como propuesta, aceptación ni como una declaración de voluntad oficial de NUCLEO S.A. La transmisión de e-mails no garantiza que
 el correo electrónico sea seguro o libre de error. Por consiguiente, no manifestamos que esta información sea completa o precisa. Toda información está sujeta a alterarse sin previo aviso.<br>
<br>
This information is private and confidential and intended for the recipient only. If you are not the intended recipient of this message you are hereby notified that any review, dissemination, distribution or copying of this message is strictly prohibited. This
 communication is for information purposes only and shall not be regarded neither as a proposal, acceptance nor as a statement of will or official statement from NUCLEO S.A. . Email transmission cannot be guaranteed to be secure or error-free. Therefore, we
 do not represent that this information is complete or accurate and it should not be relied upon as such. All information is subject to change without notice.<br>
</font>
</body>
</html>