[asterisk-users] Disposition ANSWERED but duration, billsec=0 [SEC=UNCLASSIFIED]

Calum Power Calum.Power at aad.gov.au
Thu Nov 1 22:45:20 CDT 2018

Hi Asterisk-users,

I have a bit of a hairy one for you.. that is driving me absolutely nuts to be frank.

We have an issue where our CDR records are being recorded with a zero billsec/duration on particular call cases, but not all.

See below CDR for "internal" (locally routed) call, with correct billsec/durations (dialled numbers X'd for privacy):
mysql> select * from cdr where id = '4352614'\G
*************************** 1. row ***************************
   calldate: 2018-11-02 03:02:24
       clid: "Red Shed" <XXXX>
        src: XXXX
        dst: XXXX
   dcontext: ringext
    channel: SIP/6886A7C5F3CE01-000007d5
 dstchannel: SIP/44ADD9D47A6401-000007d6
    lastapp: Dial
   lastdata: SIP/44ADD9D47A6401,60,kr(ring)
   duration: 27
    billsec: 24
disposition: ANSWERED
   amaflags: 3
   uniqueid: 1541127744.6857
       site: 8
         tz: 0
  timestamp: 2018-11-02 03:02:52
         id: 4352614
   linkedid: 1541127744.6857
1 row in set (0.00 sec)

And see following CDR which was "outbound" (routed out to another Asterisk server for PSTN connection):
mysql> select * from cdr where id = '4352617'\G
*************************** 1. row ***************************
   calldate: 2018-11-02 03:19:42
       clid: "Wallow" <XXXX>
        src: XXXX
        dst: XXXXXXXXXX
   dcontext: aad_anaresat
    channel: SIP/08CC68E8070801-000007da
 dstchannel: IAX2/cas1-kin1-19305
    lastapp: Dial
   lastdata: IAX2/ast1-cas1:@cas1-kin1/XXXXXXXXXX,90,
   duration: 0
    billsec: 0
disposition: ANSWERED
   amaflags: 3
accountcode: 784679
   uniqueid: 1541128747.6867
       site: 8
         tz: 0
  timestamp: 2018-11-02 03:19:42
         id: 4352617
   linkedid: 1541128747.6867
1 row in set (0.00 sec)

If I look at the CDR for the next leg of this call, I can see that the billsec & duration are correctly recorded as 3 & 26 respectively, which is correct. It just doesn't get recorded on the originating server.

We have only started seeing this behaviour when upgrading from 11.x to 13.x - So it's something to do with the new CDR code..
Does anyone have any idea why a CDR would EVER have a blank duration & billsec, when the disposition is ANSWERED??
Any tips would be great, because this is absolutely driving me crazy!

Thanks guys,



    Australian Antarctic Division - Commonwealth of Australia
IMPORTANT: This transmission is intended for the addressee only. If you are not the
intended recipient, you are notified that use or dissemination of this communication is
strictly prohibited by Commonwealth law. If you have received this transmission in error,
please notify the sender immediately by e-mail or by telephoning +61 3 6232 3209 and
DELETE the message.
        Visit our web site at http://www.antarctica.gov.au/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20181102/cf485e1a/attachment.html>

More information about the asterisk-users mailing list