Hello,
I have a problem in accounting INVITE. When the call is connected with duration the INVITE, ACK, BYE are accounted in db. But the problem is when the call is disconnected before it is actually attempting to connect. i am getting only CANCEL accounted whereas INVITE is not accounted for the cancelled call. I have the xlogs showing INVITE and CANCEL both for this call only no accounting is performed for INVITE.
following is the config for INVITE & CANCEL;
if (is_method("INVITE")) { setflag(1); setflag(2); # MISSED if (allow_trusted()) { rewritehostport("xx.xxx.xy.xyz:5060"); route(1); } else { sl_send_reply("401", "Unauthorized"); route(1); exit; } }
# CANCEL processing if (is_method("CANCEL")) { setflag(1); setflag(3); if (t_check_trans()) t_relay(); exit; } t_check_trans();
Please let me know what should be changed so that for the Call that is cancelled before it actually connects can have INVITE also accounted along w/ CANCEL.
Thanks, KChris.
Connect with friends all over the world. Get Yahoo! India Messenger at http://in.messenger.yahoo.com/?wm=n/
El Sábado, 1 de Noviembre de 2008, Kaeman Chris escribió:
if (is_method("CANCEL")) { setflag(1); setflag(3); if (t_check_trans()) t_relay(); exit; }
I suposse (you didn't say it) that flag(1) is the accounting flag. Well, delete the "setflag" lines above since you don't need to set accounting flags for CANCEL. If you already set acc flag during the INVITE then the CANCEL will be automatically handled by accounting module.
Hello,
I got the problem. When i was dialing a number that was directly hitting the IVR it is not accounting the INVITE and only CANCEL is accounted. not sure for this behaviour. I am investigating for this. ethereal trap & xlgos shows both INVITE and CANCEL but only acc shows CANCEL.
But when i dialed a number that was ringing before answered or pointed to VM than i am able to see the INVITE and CANCEL both accounted in cdrs as expected. but in this case i have to add the setflag lines. 1 - normal acc & 3 - failed transactions in CANCEL method.
Can you please clarify that why there is no need to add the setflag for the CANCEL method? Not working for me that way.
Thank you, KC
--- On Sun, 2/11/08, Iñaki Baz Castillo ibc@aliax.net wrote: From: Iñaki Baz Castillo ibc@aliax.net Subject: Re: [Kamailio-Users] INVITE accounting problem To: users@lists.kamailio.org Date: Sunday, 2 November, 2008, 3:49 AM
El Sábado, 1 de Noviembre de 2008, Kaeman Chris escribió:
if (is_method("CANCEL")) { setflag(1); setflag(3); if (t_check_trans()) t_relay(); exit; }
I suposse (you didn't say it) that flag(1) is the accounting flag. Well, delete the "setflag" lines above since you don't need to set accounting flags for CANCEL. If you already set acc flag during the INVITE then the CANCEL will be automatically handled by accounting module.
El Lunes, 3 de Noviembre de 2008, Kaeman Chris escribió:
Can you please clarify that why there is no need to add the setflag for the CANCEL method? Not working for me that way.
It's not needed since if an INVITE transaction is cancelled, then you will see 487 "Cancelled" as response code for that INVITE accounted transaction.
Hello,
you have to set the flag for accounting failed transactions. See the acc readme:
http://www.kamailio.org/docs/modules/1.4.x/acc.html#id2467962
Cheers, Daniel
On 11/02/08 00:09, Kaeman Chris wrote:
Hello,
I have a problem in accounting INVITE. When the call is connected with duration the INVITE, ACK, BYE are accounted in db. But the problem is when the call is disconnected before it is actually attempting to connect. i am getting only CANCEL accounted whereas INVITE is not accounted for the cancelled call. I have the xlogs showing INVITE and CANCEL both for this call only no accounting is performed for INVITE.
following is the config for INVITE & CANCEL;
if (is_method("INVITE")) { setflag(1); setflag(2); # MISSED if (allow_trusted()) { rewritehostport("xx.xxx.xy.xyz:5060"); route(1); } else { sl_send_reply("401", "Unauthorized"); route(1); exit; } } # CANCEL processing if (is_method("CANCEL")) { setflag(1); setflag(3); if (t_check_trans()) t_relay(); exit; } t_check_trans();
Please let me know what should be changed so that for the Call that is cancelled before it actually connects can have INVITE also accounted along w/ CANCEL.
Thanks, KChris.
Add more friends to your messenger and enjoy! Invite them now. http://in.rd.yahoo.com/tagline_messenger_6/*http://messenger.yahoo.com/invite/
Users mailing list Users@lists.kamailio.org http://lists.kamailio.org/cgi-bin/mailman/listinfo/users
Hello,
Yes, this is already included. I found something with further tests.
For the calls that are hitting the IVR directly it is not accounting INVITE and only CANCEL is accounted in db. I am investigating for this. ethereal trap & xlgos shows both INVITE and CANCEL but only acc in db records CANCEL.
Whereas for the calls that are ringing and hung up before being answered or hitting the VM they have both the INVITE & CANCEL accounted in db. but in this case i have to add the setflag lines. 1 - normal acc & 3 - failed transactions in CANCEL method.
Thank you, KC
--- On Mon, 3/11/08, Daniel-Constantin Mierla miconda@gmail.com wrote: From: Daniel-Constantin Mierla miconda@gmail.com Subject: Re: [Kamailio-Users] INVITE accounting problem To: kaemanchris@yahoo.co.in Cc: users@lists.kamailio.org Date: Monday, 3 November, 2008, 4:09 PM
Hello,
you have to set the flag for accounting failed transactions. See the acc readme:
http://www.kamailio.org/docs/modules/1.4.x/acc.html#id2467962
Cheers, Daniel
On 11/02/08 00:09, Kaeman Chris wrote:
Hello,
I have a problem in accounting INVITE. When the call is connected with
duration the INVITE, ACK, BYE are accounted in db. But the problem is when the call is disconnected before it is actually attempting to connect. i am getting only CANCEL accounted whereas INVITE is not accounted for the cancelled call. I have the xlogs showing INVITE and CANCEL both for this call only no accounting is performed for INVITE.
following is the config for INVITE & CANCEL;
if (is_method("INVITE")) { setflag(1); setflag(2); # MISSED if (allow_trusted()) { rewritehostport("xx.xxx.xy.xyz:5060"); route(1); } else { sl_send_reply("401",
"Unauthorized");
route(1); exit; } } # CANCEL processing if (is_method("CANCEL")) { setflag(1); setflag(3); if (t_check_trans()) t_relay(); exit; } t_check_trans();
Please let me know what should be changed so that for the Call that is
cancelled before it actually connects can have INVITE also accounted along w/ CANCEL.
Thanks, KChris.
Add more friends to your messenger and enjoy! Invite them now.
http://in.rd.yahoo.com/tagline_messenger_6/*http://messenger.yahoo.com/invite/
Users mailing list Users@lists.kamailio.org http://lists.kamailio.org/cgi-bin/mailman/listinfo/users
-- Daniel-Constantin Mierla http://www.asipto.com
Get perfect Email ID for your Resume. Grab now http://in.promos.yahoo.com/address