<div dir="ltr">Thank you all for your replies.<div><br></div><div>1- Definitely going to change from billsec to billusec</div><div>2- Going to setup tcpdump to capture traffic to see what it has to say when it fails</div><div><br></div><div>Currently, our FS servers are doing a POST request to 2 ActiveMQ&#39;s setup with a load balancer in front of them.</div><div><br></div><div>Will update when I have more info.</div><div><br></div><div>Thanks!</div><div>Joel.</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Apr 15, 2016 at 8:43 AM, François <span dir="ltr">&lt;<a href="mailto:fdelawarde@wirelessmundi.com" target="_blank">fdelawarde@wirelessmundi.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Watch out with billsec is the integer part of the &quot;real&quot; billing seconds.<br>
<br>
So if a call has duration of 10.9 seconds, billsec will be 10 seconds,<br>
but your provider will bill you 11 seconds.<br>
<br>
One should use billusec!<br>
<span class="HOEnZb"><font color="#888888"><br>
F<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
On 2016-04-15 16:19, Michael Giagnocavo wrote:<br>
&gt; One easy way, PCAP your HTTP. You can setup a rotating set of files, then when you have an issue, break the capture and hunt for the failed POST. That should give you &quot;ground truth&quot; as to what&#39;s going on and may point you to the issue.<br>
&gt;<br>
&gt; -Michael<br>
&gt;<br>
&gt; From: <a href="mailto:freeswitch-users-bounces@lists.freeswitch.org">freeswitch-users-bounces@lists.freeswitch.org</a> [mailto:<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org">freeswitch-users-bounces@lists.freeswitch.org</a>] On Behalf Of Sergey Safarov<br>
&gt; Sent: Wednesday, 13 April, 2016 22:11<br>
&gt; To: FreeSWITCH Users Help &lt;<a href="mailto:freeswitch-users@lists.freeswitch.org">freeswitch-users@lists.freeswitch.org</a>&gt;<br>
&gt; Subject: Re: [Freeswitch-users] Billsec in dialplan<br>
&gt;<br>
&gt; Please also check mod_format<br>
&gt;<br>
&gt; On Thu, Apr 14, 2016, 02:16 Ken Rice &lt;<a href="mailto:krice@freeswitch.org">krice@freeswitch.org</a>&gt; wrote:<br>
&gt; The correct answer here is you must check more often i would say at a minimum every 15 seconds. Search the list for me discussing cdrs in volume in the past or contact me off list if you need pro help<br>
&gt;<br>
&gt; Sent from my iPhone<br>
&gt;<br>
&gt; On Apr 13, 2016, at 5:52 PM, Joel Serrano &lt;<a href="mailto:joel@gogii.net">joel@gogii.net</a>&gt; wrote:<br>
&gt; Hi Michael,<br>
&gt;<br>
&gt; The problem is that occasionally we see the following in FS log:<br>
&gt;<br>
&gt; 2016-04-13 02:33:11.143230 [ERR] mod_xml_cdr.c:385 Got error [0] posting to web server [<a href="http://cdrs.example.com/queue" rel="noreferrer" target="_blank">http://cdrs.example.com/queue</a>]<br>
&gt; 2016-04-13 02:33:11.143230 [ERR] mod_xml_cdr.c:392 Retry will be with url [<a href="http://cdrs.example.com/queue" rel="noreferrer" target="_blank">http://cdrs.example.com/queue</a>]<br>
&gt;<br>
&gt; When that happens, the CDR gets written to disc (so the CDR is not processed on time, thus our user is not billed for that call yet).<br>
&gt;<br>
&gt; We have a task that checks every 5 minutes for failed CDRs and we resubmit them to the processing queue, but I need to find out why FS is failing.<br>
&gt;<br>
&gt; I have checked the access logs on the receiving side, but all requests return a 200 OK.<br>
&gt;<br>
&gt; Now I have enabled logs in the loadbalancer between FS and the queues to see if I get more vision from there...<br>
&gt;<br>
&gt;<br>
&gt; A workaround was to make API requests directly from the dialplan with the billsec info, but as all suggest going with CDRs, I am now focussed on finding the root cause for that error.<br>
&gt;<br>
&gt; Any help/suggestion is more than welcome.<br>
&gt;<br>
&gt;<br>
&gt; Thank you.<br>
&gt;<br>
&gt; Best regards,<br>
&gt; Joel.<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; On Tue, Apr 12, 2016 at 1:42 PM, Michael Jerris &lt;<a href="mailto:mike@jerris.com">mike@jerris.com</a>&gt; wrote:<br>
&gt; I&#39;m probably going to push towards cdr, but what are you trying to actually do with that info?<br>
&gt;<br>
&gt; On Apr 12, 2016, at 2:39 PM, Joel Serrano &lt;<a href="mailto:joel@gogii.net">joel@gogii.net</a>&gt; wrote:<br>
&gt;<br>
&gt; Hi Michael,<br>
&gt;<br>
&gt; I want to call an API basically with the following info:<br>
&gt;<br>
&gt; sip_from_uri<br>
&gt; destination_number<br>
&gt; billsec<br>
&gt;<br>
&gt; I found away using &quot;api_hangup_hook=lua script.lua&quot; + &quot;session_in_hangup_hook=true&quot;, but, I don&#39;t like it... I would prefer using curl from within the dialplan.<br>
&gt;<br>
&gt; Can you give me your suggestion? I have also asked in IRC and using the CDRs looks like the best way to go, so we will probably follow that, but I would still like to now if it is possible and how.<br>
&gt;<br>
&gt; Thanks!<br>
&gt; Joel.<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; On Tue, Apr 12, 2016 at 12:22 PM, Michael Jerris &lt;<a href="mailto:mike@jerris.com">mike@jerris.com</a>&gt; wrote:<br>
&gt; Billsec is set in reporting state, after you are out of dial plan.   What are you trying to do based on that, I can suggest a few approaches<br>
&gt;<br>
&gt;<br>
&gt; On Monday, April 11, 2016, Joel Serrano &lt;<a href="mailto:joel@gogii.net">joel@gogii.net</a>&gt; wrote:<br>
&gt; Hi,<br>
&gt;<br>
&gt; Is it possible to access ${billsec} in the dialplan after the bridge application (having hangup_after_bridge=false)??<br>
&gt;<br>
&gt; I want to log the billsec but currently it is always empty.<br>
&gt;<br>
&gt; I have a workaround in a test server using api_hangup_hook to call a lua script with session_in_hangup_hook=true, and inside the lua script I can access the billsec variable and thus write it to the logs.<br>
&gt;<br>
&gt; Is there no way to do this within the XML dialplan?<br>
&gt;<br>
&gt; Thanks!<br>
&gt;<br>
&gt; Best regards,<br>
&gt; Joel.<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; _________________________________________________________________________<br>
&gt; Professional FreeSWITCH Consulting Services:<br>
&gt; <a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
&gt; <a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
&gt;<br>
&gt; Official FreeSWITCH Sites<br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; <a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
&gt; <a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
&gt;<br>
&gt; FreeSWITCH-users mailing list<br>
&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt;<br>
&gt; _________________________________________________________________________<br>
&gt; Professional FreeSWITCH Consulting Services:<br>
&gt; <a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
&gt; <a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
&gt;<br>
&gt; Official FreeSWITCH Sites<br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; <a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
&gt; <a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
&gt;<br>
&gt; FreeSWITCH-users mailing list<br>
&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; _________________________________________________________________________<br>
&gt; Professional FreeSWITCH Consulting Services:<br>
&gt; <a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
&gt; <a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
&gt;<br>
&gt; Official FreeSWITCH Sites<br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; <a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
&gt; <a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
&gt;<br>
&gt; FreeSWITCH-users mailing list<br>
&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; _________________________________________________________________________<br>
&gt; Professional FreeSWITCH Consulting Services:<br>
&gt; <a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
&gt; <a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
&gt;<br>
&gt; Official FreeSWITCH Sites<br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
&gt; <a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
&gt; <a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
&gt;<br>
&gt; FreeSWITCH-users mailing list<br>
&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt; <a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<br>
<br>
_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
</div></div></blockquote></div><br></div>