Thanks for your reply.My problem was solved after I use  setflag(FTL_ACCFAILED) in failure route.
Best Regards.
From: Daniel-Constantin Mierla
Sent: Friday, March 14, 2014 10:19 PM
To: Kamailio (SER) - Users Mailing List
Subject: Re: [SR-Users] db logging for unsuccessful calls
Hello,

if you defined WITH_ACCDB, then the records should be in the acc table, provided that you created the extra columns. Look at your syslog (/var/log/syslog or /var/log/messages) to see if there is any error.

To aggregate INVITE and BYE records for getting full CDRs, you need to write a script for it. You can eventually reuse the stored procedure from siremis, you can find it at:

- http://sourceforge.net/p/siremis/git/ci/master/tree/siremis/modules/ser/mod.install.siremis.sql

The stored procedure can be called from kamailio.cfg, hints at:

- http://kb.asipto.com/siremis:install40x:accounting#kamailiocfg_for_generating_and_rating_cdrs

Cheers,
Daniel

On 14/03/14 14:42, betul.cerit@netgsm.com.tr wrote:
Hi to all,
I could hardly make kamailio log cdr to db but it just logs successful calls.I need cdr of unsuccessful calls also.I used to use asterisk so in cdr I need duration and billsec separately.As far as I understand kamailio can give only one of them.Is there a way to get them? Here is my acc configuration: #!ifdef WITH_ACCDB modparam("acc", "cdr_enable", 1) modparam("acc", "early_media", 0) modparam("acc", "report_ack", 1) modparam("acc", "report_cancels", 1) modparam("acc", "detect_direction", 0) modparam("acc", "db_url", "mysql://root: secret@localhost/mydb") modparam("acc", "log_flag", FLT_ACC) modparam("acc", "db_missed_flag", FLT_ACCMISSED) modparam("acc", "db_table_missed_calls", "missed_calls") modparam("acc", "db_flag", 1) modparam("acc", "db_missed_flag", 3) modparam("acc", "db_extra","src_user=$fU;src_domain=$fd;src_ip=$si;dst_user=$rU;dst_domain=$rd")#!endif What should I exactly do?Can someone help? Thanks in Advance. BETÜL CERİT

_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference - April 2-4, 2014, Berlin, Germany
http://www.kamailioworld.com


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users