Asterisk CDRs

Home » Asterisk Users » Asterisk CDRs
Asterisk Users 5 Comments

Hi all,

It disturbs me to see asterisk (v writing CDRs even when there
are 0 active channels and 0 active calls. Is there an upper limit in terms
of CDRs / second that asterisk can handle? Does it queue the unwritten CDRs
Please help me clarify this confusion.


5 thoughts on - Asterisk CDRs

  • Asterisk can cache cdr records to avoid having to write continuosly in the
    cdr backend. Writing in bunch instead one at once improves performance.
    Check the cdr.conf file and disable the option “batch” if it hurts you.

    Il giorno 02/mar/2012 07:24, “[Digital^Dude] ®”
    ha scritto:

  • I’ve tried with batch enabled as well as disabled, it seems irrespective of
    the call burst I send to asterisk. CDR writes at a constant speed, not
    changing with the call load!

  • Really interesting finding. From my point of view, it is a good thing.
    Having spike in cpu load will harm voice quality for sure, but it can hurts
    if you are relaying on prompt write of cdr records.

    What cdr backend are you using? Maybe the constant speed you see is the
    maximal write speed the backend can receive.

    A silly question … have you reloaded the cdr module once made the changes?


    2012/3/2 [Digital^Dude] ®

  • I tried it on asterisk version 1.8 as well as other minor releases of 1.6.
    Its the same. Not a silly question, since silly products usually have
    instantaneous errors vanished by a silly action 🙂
    I tried changing different parameters in cdr.conf and reloading multiple
    Yes, I am just using the default CDR backend and I check CDR population via
    By the way, even if I use the mysql backend, its the same result. the CPU
    load is negligible and call quality is fine but still CDR write speed is
    almost 1 entry /1.5 second. I highly doubt that would be the max write

    The kind of call burst I get on my asterisk box, tail -f Master.csv should
    be an unreadable scroll of entries!
    Hasn’t *anyone *noticed it?

  • I am using AMI Originate on asterisk 1.8.11 on SIP channels. I have set
    unanswered=yes in cdr.conf because I want to log “NO ANSWER” and “BUSY”
    The issue is, that if a SIP peer is not registered, and an originate
    request is made for that peer, a null cdr entry is made as follows:

    “”,””,””,””,””,””,””,””,””,”2012-04-05 09:28:53″,,”2012-04-05

    How can I fix it? Or, how can I set cdr not to log entries if a channel
    doesn’t exist.