[asterisk-bugs] [Asterisk 0016559]: [patch] Duration and Billsec Decimal Place

Asterisk Bug Tracker noreply at bugs.digium.com
Tue Feb 9 10:57:29 CST 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=16559 
====================================================================== 
Reported By:                cianmaher
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   16559
Category:                   Addons/cdr_addon_mysql
Reproducibility:            have not tried
Severity:                   feature
Priority:                   normal
Status:                     ready for review
Asterisk Version:           1.6.2.0 
JIRA:                        
Regression:                 No 
Reviewboard Link:           https://reviewboard.asterisk.org/r/461/ 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-01-06 14:22 CST
Last Modified:              2010-02-09 10:57 CST
====================================================================== 
Summary:                    [patch] Duration and Billsec Decimal Place
Description: 
My problem at present is I has Sangoma ss7 box, woomera, asterisk1.6.2 and
addons 1.6.2 on a server that is connected to 8 ss7 trunks with other
carriers. I have asterisk writing cdr's to mysql however it appears to
round up always. 

For example:

One of the Carriers reports a call duration of 31.7seconds but we report
it as 33seconds assuming because there is some transit duration of approx
0.4 - 0.5 of a second which brings me to 32.1 or 32.2 but then it is
rounded up to 33.

My questions are:

* Is it possible for asterisk not to round the duration and billsec?
* Is it possible to show duration and billsec with a decimal to show the
true figure?

Thanks in advance

======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
duplicate of        0016715 Billing Differences between Carrier and...
====================================================================== 

---------------------------------------------------------------------- 
 (0117891) cianmaher (reporter) - 2010-02-09 10:57
 https://issues.asterisk.org/view.php?id=16559#c117891 
---------------------------------------------------------------------- 
Ok guys I have dome some testing directly with our carrier and have found
that every call is around 0.5 seconds out. 

Example:

Asterisk Duration:  22.5197
Sangoma mpt2 Trace Duration: 22.00970
Carrier Duration: 21.9

While this duration does not seem significant in the general pbx world but
its a different story when interconnecting with a carrier.

Both the carrier and the Sangoma traces durations are taken from ANM and
RLC in the mtp2 messages. The carrier is using a Nortel DMS and the sangoma
durations are pretty close.

I am not proficient in C to try an understand what asterisk is doing that
is causing this difference in durations. I would like to understand when
asterisk considers a call started and finished as this is probably where my
problem resides.

Thanks all for your help so far.

Also to note despite asterisk answering the call immediately the duration
and billsec fields differ usually by 0.14ish of a second. Some examples
are:

call   duration    billsec
1   |  35.5124 | 35.3704 
2   |  44.5764 | 44.4354
3   |  127.304 | 127.161 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-02-09 10:57 cianmaher      Note Added: 0117891                          
======================================================================




More information about the asterisk-bugs mailing list