[OpenSIPS-Users] Doing the CDR dance

Brett Nemeroff brett at nemeroff.com
Thu Jan 27 18:34:07 CET 2011


On Thu, Jan 27, 2011 at 11:26 AM, Jock McKechnie
<jock.mckechnie at gmail.com>wrote:

> Greetings all;
>
> I'm having a devil of a time getting CDR logging functioning. I've gone
> over the ACC documentation six ways from Sunday, and I've googled like crazy
> trying to find a sample configuration that might've been logged somewhere,
> but I'm not finding anything. Either that, or I'm as daft as a brush.
>
> I've got OpenSIPS logging console details to log_local7, which I'm
> redirecting using rsyslog to /var/log/opensips.log. I'm now trying to get
> CDRs generated and recorded _to disk_ to /var/log/opensips.cdr via
> log_local6. I've got rsyslog correctly configured for pushing local6 to the
> aforementioned file, and rsylogd has created the file, but call after call,
> no details get filtered into it.
>
> I've got the following (obviously I'm omitting huge chunks of config, but
> this should be the "relevant" stuff):
>
> loadmodule("dialog.so")
> loadmodule("acc.so")
>
> modparam("acc", "log_facility", "log_local6")
> modparam("acc", "cdr_flag", 1)
>
> if (method=="INVITE") {
>    setflag(1);
>    route(1);
>    }
>
>
So two things I notice:

First you don't have a log flag defined:
http://www.opensips.org/html/docs/modules/1.6.x/acc.html#id293011

Second, you don't have anything creating a dialog.
http://www.opensips.org/html/docs/modules/1.6.x/dialog.html#id293813

Without that the cdr_flag won't do anything I don't think.

Try:
loadmodule("dialog.so")
loadmodule("acc.so")

modparam("acc", "log_facility", "log_local6")
modparam("acc", "cdr_flag", 1)
modparam("acc", "log_flag", 2)

if (method=="INVITE") {
   create_dialog()
   setflag(1);
   setflag(2);
   route(1);
   }

Let us know!
-Brett
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20110127/e521e709/attachment-0001.htm>


More information about the Users mailing list