Failover mechanism, SIP response code mapping, Length of called number control

373 views
Skip to first unread message

kt

unread,
Aug 17, 2016, 1:28:05 AM8/17/16
to ASTPP
Hello all,

Sorry that I have 3 questions below, appreciated if anyone can give me some idea, thanks.


1. I would like to know how ASTPP/Freeswitch do failover?

I found previous post but sorry that I could not get my answer.

Let's say I have 2 termination providers for the same destination(91 India), and I have created 1 rate group(default using LCR) for 1 customer, with 2 termination rates, 2 trunks, 2 gateway:

Customer A
Rate Group default
Trunk A (linked with GW A) > Termination Rate (code 91 with US$ 0.01)
Trunk B (linked with GW B) > Termination Rate (code 91 with US$ 0.02)

In this case, if the "routing type" of the rate group is "LCR", the call will go to Trunk A, right?

My question is...if Trunk A returned SIP 503, can ASTPP try to send the same call to Trunk B as failover?

if yes,
a. Do I need any specific settings for doing this? Seems the setting "failover GW1/2" is not suitable for my case, what I need is "failover trunk".
b. Which SIP response code will ASTPP do the failover? Can I control the failover only for 503 returned? and other error (e.g 403,404,480 etc.) just drop the call immediately?



2. Can I customize the cause code mapping? and where is the settings?

Let's say provider returned SIP 480, can I return 503 to originating party(customer) instead?



3. Can I control the length of called number from customer?

For example: only allow called number > 12 digit, otherwise the call will be released/rejected immediately.




Thanks.


Hardik Patel

unread,
Aug 17, 2016, 2:28:27 AM8/17/16
to as...@googlegroups.com
Hi Kt,


ASTPP/Freeswitch do failover in case of you call rejecting from the provider end then it will try to attempt that call via second gateway.

To configure failover gateway you can simply add failover gateway in trunks from the ASTPP GUI.


2. Can I customize the cause code mapping? and where is the settings?
[Answer] : Yes, it is possible to customize it but that need so customization in call script code.


3. Can I control the length of called number from customer?
For example: only allow called number > 12 digit, otherwise the call will be released/rejected immediately.
[Answer] : Yes, it is possible to control dial number length for customer specific.



Thanks,
Hardik Patel
iNextrix Technologies Pvt Ltd.
www.inextrix.com


--
=====================================================================
Documentation : https://astppdoc.atlassian.net/
Please contact at sa...@inextrix.com for commercial support.
---
You received this message because you are subscribed to the Google Groups "ASTPP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to astpp+unsubscribe@googlegroups.com.
To post to this group, send email to as...@googlegroups.com.
Visit this group at https://groups.google.com/group/astpp.
To view this discussion on the web visit https://groups.google.com/d/msgid/astpp/ba347215-4071-4fe4-aa52-3d30d3796bc8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

kt

unread,
Aug 17, 2016, 2:53:09 AM8/17/16
to ASTPP
Hello Hardik,

Thanks for your reply.

Seems some mis-understanding here.

1. "Failover gateway" in trunk settings, my understanding is...if gatewayA fails the call, 2nd attempt will go to gatewayB with different IP/Host.

But...if I assign gatewayB for failover of Trunk A (Trunk A is linked to Provider A account), but the IP of gatewayB is NOT belongs to Provider A, as the result, if the 2nd attempt is success via gatewayB, all billing will be messed up.

Thus "Failover Gateway" seems only suitable for same provider with multiple IP, but it is not for failover between different providers, please correct me if I am wrong, thanks.


Another question related to this is...which SIP response code will trigger ASTPP to do the failover? Can I control the failover only for 503 returned? for other error (e.g 403,404,480 etc.) just release the call immediately?


2. I see, could you please advise briefly where is the "call script code"?

3. May I know where I can control the dial number digit length? where I can found the settings?

Thanks.

To unsubscribe from this group and stop receiving emails from it, send an email to astpp+un...@googlegroups.com.

Hardik Patel

unread,
Aug 17, 2016, 7:51:55 AM8/17/16
to as...@googlegroups.com
Hi Kt,

1. Nop, its not like that in ASTPP. if there is a multiple routes available with different gateways and trunk then definitely it will do failover between multiple trunks.

2. script location is /usr/local/freeswitch/scripts/

3. again you need to do modification in call script on same location .

Thanks,
Hardik Patel
iNextrix Technologies Pvt Ltd.
www.inextrix.com


To unsubscribe from this group and stop receiving emails from it, send an email to astpp+unsubscribe@googlegroups.com.

To post to this group, send email to as...@googlegroups.com.
Visit this group at https://groups.google.com/group/astpp.

kt

unread,
Aug 17, 2016, 9:23:52 AM8/17/16
to ASTPP
Hello Hardik,

I see, so you mean ASTPP by default will do failover between multiple available trunks.

May I know in what situation(release code) it will do the failover? just like my previous question, which SIP response code it will do failover and can I control it (choose specific release code) by myself?

Thanks.

Hardik Patel

unread,
Aug 22, 2016, 3:09:42 AM8/22/16
to as...@googlegroups.com
Hi KT,

If you are bit technical and familiar with coding then you can do it by your self or simply contact us on sa...@inextrix.com we will do it for you.

Thanks,
Hardik Patel
iNextrix Technologies Pvt Ltd.
www.inextrix.com


To unsubscribe from this group and stop receiving emails from it, send an email to astpp+unsubscribe@googlegroups.com.

To post to this group, send email to as...@googlegroups.com.
Visit this group at https://groups.google.com/group/astpp.
Reply all
Reply to author
Forward
0 new messages