[OpenSIPS-Users] Request for clarification on tm timers
Flatbush Telecom
ftiuser at flatbushtelecom.com
Wed Mar 10 06:31:38 CET 2010
Thank you for the prompt response, Bogdan.
I enabled "restart_fr_on_each_reply" and found that I would enter failure
route a lot faster (immediately in most cases) however, there are occasions
when I have to wait 30 seconds for the failure route. Is there a way to set
that 30 seconds to something smaller? Is it the RT_T2 timer? How do I
specify a shorter period for RT_T2?
I have attached an example of the 30 second delay from when I receive a
negative INVITE in the reply route and when the failure route kicks in as it
appears in my syslog
Thanks for your help,
Mike Montgomery
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: enter route [13]
RequestURI=sip:50375990162 at myIPaddress RequestUser=50375990162
Source=myIPaddress Method=INVITE TO sip:50375990162 at myIPaddress
FromURI=sip:5672512350 at myIPaddress FromUser=5672512350
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: PRE Strip requested URI =
sip:50375990162 at myIPaddress
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: INFO:pdt:prefix2domain: no
prefix found in [50375990162]
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: Strip prefix >>>> requested
URI = sip:50375990162 at myIPaddress
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: Canonical URI =
sip:50375990162 at myIPaddress
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: valid CALLERID <<<<<
............ sip:5672512350 at myIPaddress
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: load gateway... flags =
<null>
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13338]: 1. next gateway... flags =
0
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13339]: enter onreply_route [2]
RequestURI=<null> RequestUser=<null> Source=nexthopIPaddress Method=INVITE
TO sip:50375990162 at myIPaddress FromURI=sip:5672512350 at myIPaddress
FromUser=5672512350
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13339]: ----- Reply Route 100
Trying = 100, Trying
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13343]: enter onreply_route [2]
RequestURI=<null> RequestUser=<null> Source=nexthopIPaddress Method=INVITE
TO sip:50375990162 at myIPaddress FromURI=sip:5672512350 at myIPaddress
FromUser=5672512350
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13343]: ----- Reply Route FAILURE
status = 503, Service Unavailable
Mar 10 00:09:25 OpenSIPS /sbin/opensips[13343]: ACC: call missed:
timestamp=1268197765;method=INVITE;from_tag=as027c059e;to_tag=3477186414-725808;call_id=1ef525222aa5126677bfec8276a376a2 at myIPaddress;code=503;reason=Service
Unavailable
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: rc_send_server: no reply
from RADIUS server OpenSIPS:1813
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: ERROR:acc:acc_rad_request:
radius-ing failed
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: enter failure_route [2]
Source=myIPaddress Method=INVITE TO sip:50375990162 at myIPaddress FROM
sip:5672512350 at myIPaddress
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: -----
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: ----- FAILURE status =
<null>
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: -----
Mar 10 00:09:55 OpenSIPS /sbin/opensips[13343]: ACC: call missed:
timestamp=1268197795;method=INVITE;from_tag=as027c059e;to_tag=;call_id=1ef525222aa5126677bfec8276a376a2 at myIPaddress;code=503;reason=Service
Unavailable
----- Original Message -----
From: <users-request at lists.opensips.org>
To: <users at lists.opensips.org>
Sent: 03/09/2010 4:00 AM
Subject: Users Digest, Vol 20, Issue 26
> Send Users mailing list submissions to
> users at lists.opensips.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> or, via email, send a message with subject or body 'help' to
> users-request at lists.opensips.org
>
> You can reach the person managing the list at
> users-owner at lists.opensips.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Users digest..."
>
>
> Today's Topics:
>
> 1. [NEW] OpenSIPS Control Panel 4.0 is released (with user
> provisioning) (Bogdan-Andrei Iancu)
> 2. Re: Load Balance for OpenSIPS Proxies (osiris123d)
> 3. basic over view of flags (Nigel Daniels)
> 4. Re: Load Balance for OpenSIPS Proxies (Stanis?aw Pitucha)
> 5. [dialog] Can't fetch data in 200 reply route of BYE (liuf)
> 6. Re: Load Balance for OpenSIPS Proxies (osiris123d)
> 7. Re: OpenSER+Asterisk+BLF (Mark Sayer)
> 8. Re: [NEW] OpenSIPS Control Panel 4.0 is released (with user
> provisioning) (TCB)
> 9. Re: [dialog] Can't fetch data in 200 reply route of BYE
> (Bogdan-Andrei Iancu)
> 10. Re: basic over view of flags (Bogdan-Andrei Iancu)
> 11. Re: Request for clarification on tm timers (Bogdan-Andrei Iancu)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 08 Mar 2010 21:37:28 +0200
> From: Bogdan-Andrei Iancu <bogdan at voice-system.ro>
> Subject: [OpenSIPS-Users] [NEW] OpenSIPS Control Panel 4.0 is released
> (with user provisioning)
> To: "users at lists.opensips.org" <users at lists.opensips.org>,
> "devel at lists.opensips.org" <devel at lists.opensips.org>,
> news at lists.opensips.org, business at lists.opensips.org
> Message-ID: <4B9551F8.9040605 at voice-system.ro>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hi all,
>
> A new major release of OpenSIPS Control Panel is available. This new
> release bring radical changes, as CP is not any more only a system
> provisioning tool, but a complete OpenSIPS provisioning interface.
>
> OpenSIPS CP 4.0 brings users and admin management tools - yes, now you
> can add, edit, remove OpenSIPS users (see online/offline users) and
> administrators (with permissions) for the web interface.
>
> Also OpenSIPS CP 4.0 comes with more system tools like "dialog" tool
> (for monitoring and terminating ongoing dialogs) and "permissions tool
> (for IP based authentication).
>
>
> Downloads are available under http://opensips-cp.sourceforge.net/
>
> Regards,
> Bogdan
>
>
> --
> Bogdan-Andrei Iancu
> www.voice-system.ro
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Mon, 8 Mar 2010 13:09:51 -0800 (PST)
> From: osiris123d <duane.larson at gmail.com>
> Subject: Re: [OpenSIPS-Users] Load Balance for OpenSIPS Proxies
> To: users at lists.opensips.org
> Message-ID: <1268082591536-4698310.post at n2.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
>
> Just doing some more research and it sounds like the best "open source"
> way
> to accomplish this is to use Ultra Monkey(LVS, Linux-HA, Ldirectord).
> Guess
> I will get this up and running and test it out. If anyone had any issue
> using Ultra Monkey or LVS please let me know. Hopefully this solves my
> needs.
> --
> View this message in context:
> http://n2.nabble.com/Load-Balance-for-OpenSIPS-Proxies-tp4693532p4698310.html
> Sent from the OpenSIPS - Users mailing list archive at Nabble.com.
>
>
>
> ------------------------------
>
> Message: 3
> Date: Mon, 8 Mar 2010 15:41:42 -0800
> From: Nigel Daniels <nigel.daniels at connectandsell.com>
> Subject: [OpenSIPS-Users] basic over view of flags
> To: users at lists.opensips.org
> Message-ID:
> <e1b260b91003081541p3f4d693em873ff999e78c32cf at mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> I am looking for a basic overview of the flags in opensips I understand
> that there are tmessage flags branch flags and script flags but what I
> cant
> find in the documentation is what there pourpose is can any one provide a
> stright forward example to the pourpose of flags in opensips and how they
> are used
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opensips.org/pipermail/users/attachments/20100308/f4a3eeb4/attachment-0001.htm
>
> ------------------------------
>
> Message: 4
> Date: Tue, 09 Mar 2010 01:31:58 +0000
> From: Stanis?aw Pitucha <viraptor at gmail.com>
> Subject: Re: [OpenSIPS-Users] Load Balance for OpenSIPS Proxies
> To: users at lists.opensips.org
> Message-ID: <4B95A50E.9060009 at gmail.com>
> Content-Type: text/plain; charset=UTF-8
>
> On 08.03.2010 05:05, osiris123d wrote:
>> Have two servers using Linux Heartbeat and have OpenSIPS Load Balancer
>> running on it. The load balancer will balance between two OpenSIPS proxy
>> servers. This way I have 100% redundancy.
>
> Complicated.
> Why not simply 2 proxies running with Heartbeat / Carp / vrrp /
> whatever? If one fails, you get the ip address on the other host and
> work as normal.
>
>
>
> ------------------------------
>
> Message: 5
> Date: Mon, 8 Mar 2010 18:25:08 -0800 (PST)
> From: liuf <liuf at ffcs.cn>
> Subject: [OpenSIPS-Users] [dialog] Can't fetch data in 200 reply route
> of BYE
> To: users at lists.opensips.org
> Message-ID: <1268101508759-4699883.post at n2.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
>
> When I used fetch_dlg_value to get data in 200 reply route of BYE, it
> always
> empty.
>
> I read some source about dialog module, I had discovered some possible
> mistakes in function dlg_onreq() (file dlg_handles.c)(svn rev
> 6658)(2010-03-08)
>
> When opensips receive 'BYE', current_dlg_pointer must be not null, and
> current_dlg_pointer had been initiated, so this function will be return
> before 't->dialog_ctx = (void*)current_dlg_pointer;' be exec. So in 200
> reply of BYE, can't get dialog pointer.
>
> I'm not sure this problem really exits? Would you please confirm it?
>
> function dlg_onreq() (svn rev 6658 2010-03-08)
> ==============================================
> void dlg_onreq(struct cell* t, int type, struct tmcb_params *param)
> {
> /* is the dialog already created? */
> if (current_dlg_pointer!=NULL) {
> /* new, un-initialized dialog ? */
> if ( current_dlg_pointer->flags & DLG_FLAG_ISINIT )
> return;
>
> /* dialog was previously created by create_dialog()
> -> just do the last settings */
> run_create_callbacks( current_dlg_pointer, param->req);
>
> current_dlg_pointer->lifetime = get_dlg_timeout(param->req);
>
> if (param->req->flags&bye_on_timeout_flag)
> current_dlg_pointer->flags |= DLG_FLAG_BYEONTIMEOUT;
>
> t->dialog_ctx = (void*)current_dlg_pointer;
>
> /* dialog is fully initialized */
> current_dlg_pointer->flags |= DLG_FLAG_ISINIT;
> } else {
> ......
> ========================================================
> --
> View this message in context:
> http://n2.nabble.com/dialog-Can-t-fetch-data-in-200-reply-route-of-BYE-tp4699883p4699883.html
> Sent from the OpenSIPS - Users mailing list archive at Nabble.com.
>
>
>
> ------------------------------
>
> Message: 6
> Date: Mon, 8 Mar 2010 20:49:57 -0800 (PST)
> From: osiris123d <duane.larson at gmail.com>
> Subject: Re: [OpenSIPS-Users] Load Balance for OpenSIPS Proxies
> To: users at lists.opensips.org
> Message-ID: <1268110197013-4700306.post at n2.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
>
> That would work if all I ever needed was one proxy to handle everything.
> Heartbeat/Carp/VRRP doesn't scale well if the one box is being overloaded.
> Active/Active is better than Active/Standby. And from the sounds of
> UltraMonkey you can keep adding more servers.
> --
> View this message in context:
> http://n2.nabble.com/Load-Balance-for-OpenSIPS-Proxies-tp4693532p4700306.html
> Sent from the OpenSIPS - Users mailing list archive at Nabble.com.
>
>
>
> ------------------------------
>
> Message: 7
> Date: Tue, 09 Mar 2010 17:56:52 +1300
> From: Mark Sayer <datapipes at avtb.co.nz>
> Subject: Re: [OpenSIPS-Users] OpenSER+Asterisk+BLF
> To: OpenSIPS users mailling list <users at lists.opensips.org>
> Message-ID: <20100309050035.485F524CC2E at mail.unleash.net.nz>
> Content-Type: text/plain; charset="us-ascii"; format=flowed
>
> All right I'm convinced and have started the migration from OpenSER
> 1.2 to OpenSIPS 1.6. Can anyone point me to list of database changes
> between these two? I've gotten 1.6 to run right out of the can which
> is nice and the config file differences don't look too bad. VMA - I
> might get back to you with any problems as you've done this recently.
>
> Mark
>
> At 02:28 a.m. 09/03/2010, you wrote:
>>Hi Mark,
>>
>>On Sunday7Mar, 2010, at 1:21 AM, Mark Sayer wrote:
>>
>> > We are needing to modify the configure of a currently operating
>> > OpenSER to properly relay the SUBSCRIBE and SIP-NOTIFY messages that
>> > are sent between Asterisk and a phone that supports BLF (like the
>> > Snom 300 or Yealink T26). Our setup includes an OpenSER 1.2 &
>> > Asterisk 1.4.17 in the same box. OpenSER performs all registration,
>> > authentication and NAT. Asterisk handles the media and the accounting.
>>
>>I am facing the exact same issue on my platform. The only solution I
>>have found is to upgrade to opensips 1.6 and implement the presence on
>>the proxy. AFAIK asterisk can't handle presence for devices not
>>directly registered to it.
>>
>>BTW, the config migration from 1.2 to 1.6 was less complicated than I
>>feared...
>>
>>Regards,
>>- vma
>>.
>>
>>
>>
>>_______________________________________________
>>Users mailing list
>>Users at lists.opensips.org
>>http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
>
>
> ------------------------------
>
> Message: 8
> Date: Tue, 9 Mar 2010 07:19:17 +0200
> From: TCB <tawandac at gmail.com>
> Subject: Re: [OpenSIPS-Users] [NEW] OpenSIPS Control Panel 4.0 is
> released (with user provisioning)
> To: OpenSIPS users mailling list <users at lists.opensips.org>
> Message-ID:
> <f9db9e001003082119g2b83b4c1sdbf2dc5b692bf90c at mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Looking good. Well done.
>
> On Mon, Mar 8, 2010 at 9:37 PM, Bogdan-Andrei Iancu
> <bogdan at voice-system.ro>wrote:
>
>> Hi all,
>>
>> A new major release of OpenSIPS Control Panel is available. This new
>> release bring radical changes, as CP is not any more only a system
>> provisioning tool, but a complete OpenSIPS provisioning interface.
>>
>> OpenSIPS CP 4.0 brings users and admin management tools - yes, now you
>> can add, edit, remove OpenSIPS users (see online/offline users) and
>> administrators (with permissions) for the web interface.
>>
>> Also OpenSIPS CP 4.0 comes with more system tools like "dialog" tool
>> (for monitoring and terminating ongoing dialogs) and "permissions tool
>> (for IP based authentication).
>>
>>
>> Downloads are available under http://opensips-cp.sourceforge.net/
>>
>> Regards,
>> Bogdan
>>
>>
>> --
>> Bogdan-Andrei Iancu
>> www.voice-system.ro
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>
>
>
> --
> TC
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.opensips.org/pipermail/users/attachments/20100309/8e4c1c77/attachment-0001.htm
>
> ------------------------------
>
> Message: 9
> Date: Tue, 09 Mar 2010 10:36:49 +0200
> From: Bogdan-Andrei Iancu <bogdan at voice-system.ro>
> Subject: Re: [OpenSIPS-Users] [dialog] Can't fetch data in 200 reply
> route of BYE
> To: OpenSIPS users mailling list <users at lists.opensips.org>
> Message-ID: <4B9608A1.5040504 at voice-system.ro>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hi Liuf,
>
> dlg_onreq() function is intended to be called/used only for initial
> requests (for the INVITEs creating a dialog).
>
> So, this function is not intended to be used for BYE request - the BYE
> is handled via the dlg_onroute() function which is used for all
> sequential requests.
>
> If you find any issues is some parts of the code, please let me know and
> I will take care.
>
> Regards,
> Bogdan
>
> liuf wrote:
>> When I used fetch_dlg_value to get data in 200 reply route of BYE, it
>> always
>> empty.
>>
>> I read some source about dialog module, I had discovered some possible
>> mistakes in function dlg_onreq() (file dlg_handles.c)(svn rev
>> 6658)(2010-03-08)
>>
>> When opensips receive 'BYE', current_dlg_pointer must be not null, and
>> current_dlg_pointer had been initiated, so this function will be return
>> before 't->dialog_ctx = (void*)current_dlg_pointer;' be exec. So in 200
>> reply of BYE, can't get dialog pointer.
>>
>> I'm not sure this problem really exits? Would you please confirm it?
>>
>> function dlg_onreq() (svn rev 6658 2010-03-08)
>> ==============================================
>> void dlg_onreq(struct cell* t, int type, struct tmcb_params *param)
>> {
>> /* is the dialog already created? */
>> if (current_dlg_pointer!=NULL) {
>> /* new, un-initialized dialog ? */
>> if ( current_dlg_pointer->flags & DLG_FLAG_ISINIT )
>> return;
>>
>> /* dialog was previously created by create_dialog()
>> -> just do the last settings */
>> run_create_callbacks( current_dlg_pointer, param->req);
>>
>> current_dlg_pointer->lifetime = get_dlg_timeout(param->req);
>>
>> if (param->req->flags&bye_on_timeout_flag)
>> current_dlg_pointer->flags |= DLG_FLAG_BYEONTIMEOUT;
>>
>> t->dialog_ctx = (void*)current_dlg_pointer;
>>
>> /* dialog is fully initialized */
>> current_dlg_pointer->flags |= DLG_FLAG_ISINIT;
>> } else {
>> ......
>> ========================================================
>>
>
>
> --
> Bogdan-Andrei Iancu
> www.voice-system.ro
>
>
>
>
> ------------------------------
>
> Message: 10
> Date: Tue, 09 Mar 2010 10:40:44 +0200
> From: Bogdan-Andrei Iancu <bogdan at voice-system.ro>
> Subject: Re: [OpenSIPS-Users] basic over view of flags
> To: OpenSIPS users mailling list <users at lists.opensips.org>
> Message-ID: <4B96098C.1010600 at voice-system.ro>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hi Nigel,
>
> Have you went through the flags docs
> (http://www.opensips.org/Resources/DocsCoreFlags16) ? There you have a
> good explanation on the flag types and behaviours.
>
> For what to use them, there are 2 cases:
> 1) to signal some actions to some modules (like via flags you
> trigger the accounting in acc module)
> 2) for whatever scripting purposes you need - like to remember if
> the requests came from a GW, to mark a state for later processing in
> failure route, to mark a message as coming from behind a nat, etc...
>
> Regards,
> Bogdan
>
> Nigel Daniels wrote:
>> I am looking for a basic overview of the flags in opensips I
>> understand that there are tmessage flags branch flags and script flags
>> but what I cant find in the documentation is what there pourpose is
>> can any one provide a stright forward example to the pourpose of flags
>> in opensips and how they are used
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>
>
> --
> Bogdan-Andrei Iancu
> www.voice-system.ro
>
>
>
>
> ------------------------------
>
> Message: 11
> Date: Tue, 09 Mar 2010 11:00:05 +0200
> From: Bogdan-Andrei Iancu <bogdan at voice-system.ro>
> Subject: Re: [OpenSIPS-Users] Request for clarification on tm timers
> To: OpenSIPS users mailling list <users at lists.opensips.org>
> Message-ID: <4B960E15.902 at voice-system.ro>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hi,
>
> First of all, if you want to dynamically change the final response
> timeout (fr_timeout), you need to have the "restart_fr_on_each_reply"
> enabled .See :
> http://www.opensips.org/html/docs/modules/1.6.x/tm.html#id270372
>
> Regards,
> Bodgan
>
> Flatbush Telecom wrote:
>> I have a question regarding the final response and how to accelerate
>> failover.
>>
>> I have studied the documentation and have watched the discussions
>> regarding fr_timer and fr_inv_timer. I do not think I understand the
>> fine points of tm and would appreciated your assistance.
>>
>> My question is how do I accelerate the final response back to UAC?
>> Right now it takes up to 30 seconds from when I know I have received a
>> negative response to INVITE until my failure_route gets executed. If I
>> do not call failure_route, it still takes up to 30 seconds
>>
>> Right now when UAC sends an INVITE, fr_timer has a default value of 3.
>> In my onreply_route, fr_inv_timer gets set to 30 when I receive
>> provisional response 100. If there is further progress to a
>> provisional response >= 180, fr_inv_timer gets set to 90. If I receive
>> a negative response, I call failure _route from my onreply_route.
>>
>> At that point, I know I have received a negative acknowledge but will
>> not signal UAC for another 30 seconds that the call failed.
>>
>> I have attached appropriate pieces of my config your your review.
>> Thank you very much for any help you can provide.
>>
>> Mike Montgomery
>>
>> # ------------lcr params (to get to functionality) ------------
>> modparam("lcr", "contact_avp", "$avp(i:711)")
>> modparam("lcr|tm", "fr_inv_timer_avp", "$avp(i:704)")
>> modparam("lcr", "gw_uri_avp", "$avp(i:709)")
>> modparam("^auth$|lcr", "rpid_avp", "$avp(i:302)")
>> modparam("lcr", "ruri_user_avp", "$avp(i:500)")
>> modparam("lcr", "flags_avp", "$avp(i:712)")
>> /* Turning on the regex mode for prefix */
>> #modparam("lcr", "prefix_mode", 1)
>> modparam("lcr","fr_inv_timer_next",10)
>> modparam("lcr|tm","fr_inv_timer",10)
>> modparam("tm", "fr_timer", 3)
>> modparam("tm", "onreply_avp_mode", 1)
>> modparam("tm", "fr_timer_avp", "$avp(i:24)")
>> modparam("tm", "pass_provisional_replies", 1)
>> avp_aliases="fr_timer=i:24"
>> avp_aliases="fr_inv_timer=i:704"
>> modparam("tm", "restart_fr_on_each_reply", 0)
>>
>> route[13] {
>> xlog("L_INFO","enter route [13] RequestURI=$ru RequestUser=$rU
>> Source=$si Method=$rm TO $tu FromURI=$fu FromUser=$fU \n");
>> #From an external domain outbound
>> if(allow_trusted()) {
>>
>> xlog("L_INFO","PRE Strip requested URI = $ru \n");
>>
>> prefix2domain("0", "2");
>>
>> xlog("L_INFO","Strip prefix >>>> requested URI = $ru
>> \n");
>>
>> $avp(s:can_uri) = $ru;
>>
>> xlog("L_INFO"," Canonical URI = $avp(s:can_uri) \n");
>>
>> revert_uri();
>>
>> # if no caller ID add dummy callerID
>>
>> if ($fU!~"^[0-9]*") {
>> uac_replace_from("sip:14436230000@$si");
>> xlog("L_INFO","NO CALLERID inserted>>>>> ............
>> $fu \n");
>> } else {
>> xlog("L_INFO","valid CALLERID <<<<< ............ $fu
>> \n");
>> }
>>
>> if (!load_gws()) {
>> xlog("L_INFO"," load_gws() FAILED >>> gw_uri_avp =
>> $avp(i:709) \n");
>> sl_send_reply("503", "Unable to load gateways");
>> exit;
>> }
>>
>> xlog("L_INFO"," load gateway... flags = $avp(i:712) \n");
>>
>> if(!next_gw()){
>> xlog("L_INFO"," next_gw() FAILED >>> ruri_user_avp =
>> $avp(i:500) \n");
>> sl_send_reply("503", "Unable to find a gateway");
>> exit;
>> }
>> xlog("L_INFO"," 1. next gateway... flags = $avp(i:712)
>> \n");
>>
>> # set provisional response timer
>> $avp(fr_timer)=3;
>>
>> t_on_reply("2");
>>
>> if (!t_relay()) {
>> sl_reply_error();
>> };
>> exit;
>>
>> } else {
>> sl_send_reply("403", "Forbidden r13");
>> exit;
>> };
>> }
>> onreply_route[2] {
>> xlog("L_INFO","enter onreply_route [2] RequestURI=$ru
>> RequestUser=$rU Source=$si Method=$rm TO $tu FromURI=$fu FromUser=$fU
>> \n");
>>
>> if(status=~"100"){
>> $avp(fr_inv_timer) = 35;
>> xlog("L_INFO"," ----- Reply Route 100 Trying = $rs, $rr \n");
>> };
>>
>> if(status=~"18[0-3]"){
>> $avp(fr_inv_timer) = 100;
>> xlog("L_INFO"," ----- Reply Route $rs $rr \n");
>> };
>>
>> if(status=~"[3-6][0-9][0-9]"){
>> xlog("L_INFO"," ----- Reply Route FAILURE status = $rs,
>> $rr \n");
>> t_on_failure("2");
>> };
>> exit;
>> }
>>
>> failure_route[2] {
>> xlog("L_INFO","enter failure_route [2] Source=$si Method=$rm TO $tu
>> FROM $fu \n");
>> xlog("L_INFO"," ----- \n");
>> xlog("L_INFO"," ----- FAILURE status = $rs \n");
>> xlog("L_INFO"," ----- \n");
>>
>> ##--
>> ##-- If cancelled, exit.
>> ##--
>> if (t_was_cancelled()) {
>> exit;
>> };
>>
>> if (!use_next_gw()) {
>> t_reply("503", "No gateways available");
>> xlog("L_INFO"," failure route NO MORE GATEWAYS 503 back to
>> caller \n");
>> exit;
>> };
>>
>> xlog("L_INFO"," failure route next gateway... dr_ruri=
>> $avp(dr_ruri) ... dr_attrs = $avp(dr_attrs) destination = $dd \n");
>>
>> # Set accounting flags again Account INVITE packets
>> setflag(5);
>> # Set accounting flags again Account Missed calls
>> setflag(8);
>>
>> t_on_reply("2");
>>
>> t_relay();
>>
>> exit;
>> }
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>
>
> --
> Bogdan-Andrei Iancu
> www.voice-system.ro
>
>
>
>
> ------------------------------
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
> End of Users Digest, Vol 20, Issue 26
> *************************************
>
More information about the Users
mailing list