Solved

Asterisk 1.8.12 limiting incoming calls to one per sip extension

Posted on 2013-02-07
9
2,561 Views
Last Modified: 2013-02-08
Hi All,

I have a user that requested to have four lines configured on his Cisco 7960 phone with each line per softkey.  Ideally, he wants all incoming calls to roll over to each softkey as opposed to having call waiting so it'll be easier for him to pickup via the keys as opposed to having to fiddle with switching back and forth for call waiting, i.e. first calls rings extension #1 (softkey1), second incoming call rings to softkey2, and and so forth.

So my logic, and of course correct me if I'm wrong:

1) configure four different sip extensions in sip.conf, i.e. 100, 101, 102, and 103 and set "busylimit = 1" for each extension.
3) configure the sip extensions per each softkey on the Cisco 7960 phone
4) configure the extensions.conf for the incoming call do to the following:
exten => s,1,Answer()
exten => s,n,Dial(SIP/100,10,tr)
exten => s,n,Dial(SIP/101,5,tr)
exten => s,n,Dial(SIP/102,5,tr)
exten => s,n,Dial(SIP/103,5,tr)
exten => s,n,Voicemail(100@context,u)
exten => s,n,Hangup()
exten => 102,Voicemail(100@context,b)

Open in new window


does that sound correct or is there a better/different way to do so.

essentially, I just need to limit each extension to one call and have it rollover to the next extensions.

Much appreciated for guidance.
0
Comment
Question by:jetli87
  • 5
  • 4
9 Comments
 
LVL 20

Accepted Solution

by:
José Méndez earned 500 total points
ID: 38867783
That doesn't sound correct, Asterisk  will try to connect 4 different calls one after the other regardless of what happened to the first one.

Try this:

exten => s,1,Dial(SIP/100,10,tr)
exten => s,n,GotoIf($["${DIALSTATUS}" = "BUSY"]?b1:vm)
exten => s,n(b1),Dial(SIP/101,5,tr)
exten => s,n,GotoIf($["${DIALSTATUS}" = "BUSY"]?b2:vm)
exten => s,n(b2),Dial(SIP/102,5,tr)
exten => s,n,GotoIf($["${DIALSTATUS}" = "BUSY"]?b3:vm)
exten => s,n(b3),Dial(SIP/103,5,tr)
exten => s,n,GotoIf($["${DIALSTATUS}" = "BUSY"]?b4:vm)
exten => s,n(b4),Voicemail(100@context,b)
exten => s,n(vm),Voicemail(100@context,u)
exten => s,n,Hangup()

What I'm showing is the logic of using the GotoIf() to achieve what you need.

HTH
0
 
LVL 1

Author Comment

by:jetli87
ID: 38868494
Perfect!  I figured i needed "gotoif" but didn't know the code for busy detect.  Will try and get back to you.
0
 
LVL 1

Author Comment

by:jetli87
ID: 38868596
to better understand the your code, how does "b1:vm" work?  If busy is detected, send the call to b1.  Otherwise, if it's not busy, goto voicemail?  Correct?
0
 
LVL 20

Expert Comment

by:José Méndez
ID: 38868602
If it didn't find the user busy, then the call rang up to the limit (10 or 5), and then went to voicemail as unavailable.
0
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 1

Author Comment

by:jetli87
ID: 38868661
got it. When using "Dialstatus" flag, is "congestion" a usable option?  is that the interchangeable with "busy" or is there a different use for it?
0
 
LVL 20

Expert Comment

by:José Méndez
ID: 38868725
0
 
LVL 20

Expert Comment

by:José Méndez
ID: 38868727
Is the code working for you?
0
 
LVL 1

Author Comment

by:jetli87
ID: 38868761
yup, works perfect.
0
 
LVL 20

Expert Comment

by:José Méndez
ID: 38868788
Glad to hear that mate.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

There are no good configuration guides for HP-H3C router to LYNC on the web. :( Big statement, but we havent been able to find one yet. We did find the following document useful, but the information was not enough to use H3C router for use as a L…
Messaging apps are amazing tools with the power to do a lot of good, but the truth is the process of collaborating with coworkers requires relationships established through meaningful communication - the kind of communication that only happens face-…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now