Solved

Asterisk Incoming calls failing

Posted on 2009-04-03
5
1,011 Views
Last Modified: 2013-11-12
I have an Asterisk server that is connected via SIP trunk to my provider. Outbound calls work great, but inbound calls give an immediate fast busy.

Peers look registered and fine.

I do not even see messages about the call in the Asterisk console.
If I do a sniffer trace then I do see a 401 unauthorized packet that looks like it from from the incoming call.

originally I had the specific DID in the extension.conf. I changed it to _X. to try and make sure that it was not blocking it, and to have everything route to ext 2000; however, if I understand correctly, then if it was a problem with the extensions.conf file, then wouldn't I get a message at the Asterisk console of ext <DID> could not be found (or something like that).

Here are the important sections of the sip.conf

[general]
localnet=192.168.0.0/255.255.255.0
register => <userid>:<pwd>@<host>/<userid>
canreinvite=no

[2000]
type=friend
context=phones
host=dynamic
secret=<pwd>
qualify=3000

[2001]
type=friend
context=phones
host=dynamic
secret=<pwd>
qualify=3000

[2002]
type=friend
context=phones
host=dynamic
secret=<pwd>
qualify=3000

[voipvoip-outgoing]
type=peer
username=<userid>
secret=<pwd>
nat=auto
insecure=very
host=<host>
fromuser=<userid>
dtmfmode=rfc2833
disallow=all
allow=g729
allow=ilbc
allow=ulaw
allow=alaw
qualify=yes

[voipvoip-incoming]
username=<userid, not DID>
type=friend
secret=<pwd>
nat=no
insecure=very
host=<host>
dtmfmode=rfc2833
disallow=all
allow=g729
allow=ilbc
allow=ulaw
allow=alaw
context=from-trunk
qualify=yes


Here are the important sections of the extensions.conf
[internal]
exten => 2000,1,Verbose(1,Extension 2000)
exten => 2000,n,Dial(SIP/2000,30)
exten => 2000,n,Hangup()

exten => 2001,1,Verbose(1,Extension 2001)
exten => 2001,n,Dial(SIP/2001,30)
exten => 2001,n,Hangup()

exten => 2002,1,Verbose(1,Extension 2002)
exten => 2002,n,Dial(SIP/2002,30)
exten => 2002,n,Hangup()

[phones]
include => internal
include => ld_outgoing_calls
include => local_outgoing_calls
include => demo

[from-trunk]
include => internal
exten => _X.,1,Dial(SIP,2000)

[ld_outgoing_calls]
exten => _1NXXNXXXXXX,1,Dial(SIP/voipvoip-outgoing/${EXTEN})

[local_outgoing_calls]
exten => _NXXNXXXXXX,1,Dial(SIP/voipvoip-outgoing/1${EXTEN})
0
Comment
Question by:sallwine
  • 4
5 Comments
 
LVL 25

Expert Comment

by:Ron Malmstead
ID: 24065900
this is wrong...

exten => _X.,1,Dial(SIP,2000)

should be ...

exten => _X.,1,Dial(SIP/2000)
0
 
LVL 25

Expert Comment

by:Ron Malmstead
ID: 24065915
There may still be another problem if you didn't see any errors on the console when dialing in...if it hits asterisk you should see something..  but the above should definitely be changed first.

What distro are you running ?...do you have SELinux enabled ?..Ip tables setup ?
0
 
LVL 25

Accepted Solution

by:
Ron Malmstead earned 500 total points
ID: 24065927
You might also try setting NAT to auto on the incoming sip entry.

And i'm not 100 percent positive here...but I don't think you need to specify the incoming user and secret....for incoming calls from the sip trunk provider....unless the provider specifically told you too.  I think your server is challenging your provider for the user/secret, and they aren't sending one.
0
 
LVL 3

Author Comment

by:sallwine
ID: 24071637
The extension was a misprint, I had changed that already, but that should have been a / instead of a , ... in case someone looks at this in the future.
Also after I removed the authentication then calls started to come in, but said no audio could be negoiated (or something like that), so I moved my codec commands up to the general section, and it worked great.
0
 
LVL 25

Expert Comment

by:Ron Malmstead
ID: 24071975
glad I could help.

-x
0

Featured Post

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Linux guest in vmware workstation 5 90
Is this QoS Correct on this  CISCO 3825 Router 1 94
QoS for Voip 7 54
decoding the error message TEI_ASSIGNED 8 35
In my office we had 10 Cisco 7940G IP phones that were useless as they were showing PROTOCOL APPLICATION INVALID when started. I searched through Google and worked for a week continuously on those phones, and finally got them working. This is a di…
Every year the snow affects people and businesses. According to the Federation of Small Businesses (FSB), in 2009, UK businesses lost an estimated £1.2bn (http://news.bbc.co.uk/1/hi/business/7864804.stm) because of bad weather. This article was c…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

809 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