Hi,<div><br></div><div>It seems that I'm running into a timing issue with outgoing (gateway) registrations, which results in some milliseconds in that I can't send calls over that gateway.</div><div><br></div><div>
I have configured a gateway like this:</div><div><br></div><div><div><font face="'courier new', monospace"> <gateway name="duro"></font></div><div><font face="'courier new', monospace"> <param name="username" value="XXXXXXX"/></font></div>
<div><font face="'courier new', monospace"> <param name="from-domain" value="<a href="http://durosip.qsc.de">durosip.qsc.de</a>"/></font></div><div><font face="'courier new', monospace"> <param name="password" value="XXXXXXXXXXX"/></font></div>
<div><font face="'courier new', monospace"> <param name="proxy" value="<a href="http://durosip.qsc.de">durosip.qsc.de</a>"/></font></div><div><font face="'courier new', monospace"> <param name="expire-seconds" value="120"/></font></div>
<div><font face="'courier new', monospace"> <param name="register" value="true"/>^M</font></div><div><font face="'courier new', monospace"> <param name="register-transport" value="udp"/></font></div>
<div><font face="'courier new', monospace"> <param name="retry-seconds" value="5"/></font></div><div><font face="'courier new', monospace"> <param name="caller-id-in-from" value="true"/></font></div>
<div><span style="font-family:'courier new',monospace"> </gateway>^M</span></div><div><br></div><div>If I look at the "200 OK" messages for the SIP REGISTER packet, the server sends me an "Expires: 30", so FreeSwitch should re-REGISTER every 30 seconds.</div>
<div><br></div><div>However, that's what happening:</div><div><br></div></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div><div><font face="'courier new', monospace">2012-01-09 16:37:00.804865 [NOTICE] sofia_reg.c:407 Registering duro</font></div>
</div></div><div><div><div><font face="'courier new', monospace">2012-01-09 16:37:31.804880 [NOTICE] sofia_reg.c:407 Registering duro</font></div></div></div><div><div><div><font face="'courier new', monospace">2012-01-09 16:38:03.804894 [NOTICE] sofia_reg.c:407 Registering duro</font></div>
</div></div><div><div><div><font face="'courier new', monospace">2012-01-09 16:38:35.824877 [NOTICE] sofia_reg.c:407 Registering duro</font></div></div></div><div><div><div><font face="'courier new', monospace"><b>2012-01-09 16:39:06.825090 [NOTICE] sofia_reg.c:407 Registering duro</b></font></div>
</div></div><div><div><div><font face="'courier new', monospace">2012-01-09 16:39:39.824881 [NOTICE] sofia_reg.c:407 Registering duro</font></div></div></div></blockquote><div><div><br></div><div>You can see that it's <i>approximately</i> 30 seconds betwee registrations, but in fact every time it's just a little more than 30 secs. This alone makes me feel a little bit strange, since my registration might have been expired during this time window (and consequently, maybe I'm loosing incoming calls because of that).</div>
<div><br></div><div>Even for outgoing calls, this seems to be an issue, let's take a look at the 16:39:06.825090 re-REGISTER.</div><div><br></div><div>We can see that at 16:39:05 (no micro-seconds here) the gateway becomes "UNREGED":</div>
<div><br></div></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div><div><font face="'courier new', monospace">Content-Length: 542</font></div></div></div><div><div><font face="'courier new', monospace">Content-Type: text/event-plain</font></div>
</div><div><div><font face="'courier new', monospace"><br></font></div></div><div><div><font face="'courier new', monospace">Event-Subclass: sofia::gateway_state</font></div></div><div><div><font face="'courier new', monospace">Event-Name: CUSTOM</font></div>
</div><div><div><font face="'courier new', monospace">Core-UUID: 243269fe-d280-4f83-aca1-abb88f2ad258</font></div></div><div><div><font face="'courier new', monospace">FreeSWITCH-Hostname: lap597</font></div>
</div><div><div><font face="'courier new', monospace">FreeSWITCH-Switchname: lap597</font></div></div><div><div><font face="'courier new', monospace">FreeSWITCH-IPv4: 192.168.232.164</font></div></div><div>
<div><font face="'courier new', monospace">FreeSWITCH-IPv6: ::1</font></div></div><div><div><font face="'courier new', monospace"><b>Event-Date-Local: 2012-01-09 16:39:05</b></font></div></div><div><div><font face="'courier new', monospace">Event-Date-GMT: Mon, 09 Jan 2012 15:39:05 GMT</font></div>
</div><div><div><font face="'courier new', monospace">Event-Date-Timestamp: 1326123545824882</font></div></div><div><div><font face="'courier new', monospace">Event-Calling-File: sofia_reg.c</font></div></div>
<div><div><font face="'courier new', monospace">Event-Calling-Function: sofia_reg_fire_custom_gateway_state_event</font></div></div><div><div><font face="'courier new', monospace">Event-Calling-Line-Number: 151</font></div>
</div><div><div><font face="'courier new', monospace">Gateway: duro</font></div></div><div><div><font face="'courier new', monospace">State: UNREGED</font></div></div><div><div><font face="'courier new', monospace">Ping-Status: UP</font></div>
</div></blockquote><div><div><br></div><div>But the new REGISTER is done a full second later (this is not just a display issue, I saw those messages scrolling by and there was just a second pause between them):</div><div>
<br></div></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div><font face="'courier new', monospace">Event-Subclass: sofia::gateway_state</font></div></div><div><div><font face="'courier new', monospace">Event-Name: CUSTOM</font></div>
</div><div><div><font face="'courier new', monospace">Core-UUID: 243269fe-d280-4f83-aca1-abb88f2ad258</font></div></div><div><div><font face="'courier new', monospace">FreeSWITCH-Hostname: lap597</font></div>
</div><div><div><font face="'courier new', monospace">FreeSWITCH-Switchname: lap597</font></div></div><div><div><font face="'courier new', monospace">FreeSWITCH-IPv4: 192.168.232.164</font></div></div><div>
<div><font face="'courier new', monospace">FreeSWITCH-IPv6: ::1</font></div></div><div><div><font face="'courier new', monospace">Event-Date-Local: 2012-01-09 16:39:06</font></div></div><div><div><font face="'courier new', monospace"><b>Event-Date-GMT: Mon, 09 Jan 2012 15:39:06 GMT</b></font></div>
</div><div><div><font face="'courier new', monospace">Event-Date-Timestamp: 1326123546825090</font></div></div><div><div><font face="'courier new', monospace">Event-Calling-File: sofia_reg.c</font></div></div>
<div><div><font face="'courier new', monospace">Event-Calling-Function: sofia_reg_fire_custom_gateway_state_event</font></div></div><div><div><font face="'courier new', monospace">Event-Calling-Line-Number: 151</font></div>
</div><div><div><font face="'courier new', monospace">Gateway: duro</font></div></div><div><div><font face="'courier new', monospace">State: TRYING</font></div></div><div><div><font face="'courier new', monospace">Ping-Status: DOWN</font></div>
</div></blockquote><div><div><br></div><div>Then, the gateway gets re-registered in a couple of milliseconds and everything is fine again.</div><div><br></div><div><b>It seems that this behaviour effectively creates a timespan of 1-2 seconds, where the gateway is not available for outgoing (and maybe also incoming) calls.</b></div>
<div><br></div><div>Does anyone of you know this issue? I wonder because this looks just to easy to be wrong in this fashion?</div><div><br></div>Greetings,<div>Roland</div><div><br></div><br>
</div>