[RESOLVED] Problems calling outside my LAN


#1

Hi, I just successfully configured my asterisk server. I have several PC in my LAN (using x-lite) and each of them can register to the server, call and receive. The problem is when I try to call outside (ex: 16049586111@sip.like2fone.com)… I always get the message “404 Not Found”. Can anyone help me about it?
Thanks in advance!

sip.conf

[general]
context=default
port=5060
bindaddr=0.0.0.0
srvlookup=yes
realm=xxx.homelinux.net

[phone1]
type=friend
username=phone1
secret=phone1
auth=md5
callerid=“phone1”
host=dynamic
nat=yes
reinvite=no
canreinvite=no
disallow=all
allow=gsm

[phone2]
type=friend
username=phone2
secret=phone2
auth=md5
callerid=“phone2”
host=dynamic
nat=no
canreinvite=no
disallow=all
allow=gsm

extensions.conf

[general]
static=yes
writeprotect=no

[default]
exten => phone1,1,Dial(SIP/phone1,20)
exten => phone1,2,Congestion

exten => phone2,1,Dial(SIP/phone2,20)
exten => phone2,2,Congestion

X-Lite Disgnostics

SEND TIME: 16229812
SEND >> 82.52.XXX.XXX:5060
INVITE sip:16049586111@sip.like2fone.com SIP/2.0
Via: SIP/2.0/UDP 82.52.XXX.XXX:5061;rport;branch=z9hG4bK305916976F04463EA27054B34838F161
From: phone1 sip:phone1@XXX.homelinux.net:5061;tag=1029368426
To: sip:16049586111@sip.like2fone.com
Contact: sip:phone1@82.52.XXX.XXX:5061
Call-ID: 270F45ED-E125-4A52-8BCF-47CC331A512B@192.168.0.8
CSeq: 10195 INVITE
Proxy-Authorization: Digest username=“phone1”,realm=“xxx.homelinux.net”,nonce=“3b1e89b5”,response=“1c20fc8698bdadd3a00aadcaca5f0ea3”,uri="sip:16049586111@sip.like2fone.com"
Max-Forwards: 70
Content-Type: application/sdp
User-Agent: X-Lite release 1103m
Content-Length: 296

v=0
o=phone1 16229781 16229796 IN IP4 82.52.XXX.XXX
s=X-Lite
c=IN IP4 82.52.XXX.XXX
t=0 0
m=audio 8000 RTP/AVP 0 8 3 98 97 101
a=rtpmap:0 pcmu/8000
a=rtpmap:8 pcma/8000
a=rtpmap:3 gsm/8000
a=rtpmap:98 iLBC/8000
a=rtpmap:97 speex/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

RECEIVE TIME: 16229843
RECEIVE << 192.168.0.253:5060
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 82.52.XXX.XXX:5061;branch=z9hG4bK305916976F04463EA27054B34838F161;received=192.168.0.8;rport=5061
From: phone1 sip:phone1@xxx.homelinux.net:5061;tag=1029368426
To: sip:16049586111@sip.like2fone.com;tag=as6bab6759
Call-ID: 270F45ED-E125-4A52-8BCF-47CC331A512B@192.168.0.8
CSeq: 10195 INVITE
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER
Contact: sip:16049586111@192.168.0.253
Content-Length: 0


#2

I don’t see a SIP configuration for your VOIP provider in SIP.conf.

Did you forget?


#3

[quote=“dufus”]I don’t see a SIP configuration for your VOIP provider in SIP.conf.

Did you forget?[/quote]

Well, actually I was trying to configure my asterisk server as a VOIP provider… is this possible?


#4

If you can call and receive calls from your x-lite clients, then you are acting as a VOIP provider. You just have only two customers.

I you’re going to try to route calls to another network you’re going to have to setup a link to that provider.

Check out Free World Dialup. It’s a free way to attempt what you’re trying to do.

freeworlddialup.com/


#5

[quote=“dufus”]
Check out Free World Dialup. It’s a free way to attempt what you’re trying to do.

freeworlddialup.com/[/quote]

I already have an account on FWD.
If I setup an X-Lite client to access directly to FWD (following the instructions found on their site), I’m able to call all FWD numbers… AND also all outside number… as for example 16049586111@sip.like2fone.com

I would like to be able to do the same with my asterisk server. I want to call the numbers registered on it as well as any other outside number.
I have to use FWD or can I do it simply by my asterisk server?


#6

Check out this page to see how to use FWD as a link from Asterisk.

voip-info.org/wiki-Free+World+Dialup

Setup your Free World Dialup account in iax.conf, and you can use it to call from any softphone that you have registered with your Asterisk server.

You might also check out this page, which has more complete instructions:

voip-info.org/tiki-index.php … ect+to+FWD


#7

The solution is much easier: adding this line in the extensions.conf

exten => _9.,1,Dial(SIP/${EXTEN:1}@${SIPDOMAIN},30,r)

And then you just need to add 9 in front of the outside number to call.

Ex:
9612@fwd.pulver.com
916044845289@sip.like2fone.com

(PS. no FWD sign up is required)


#8

Yes. That will allow outcalling to FWD and other destinations, but if you want incoming calls, you need to register with FWD or some other VOIP provider.


#9

Why? Can’t I use a dyndns account and open the udp/5060 on the firewall?
People from other VOIP providers will be able to call me on:

phone1@mydomain.dyndns.org
phone2@mydomain.dyndns.org

Am I wrong?


#10

You’re assuming that people would want to call SIP phones by dialing client machine names.

The advantage of VOIP accounts is that they give you phone numbers that translate to your clients machine name.

It’s far easier to call a phone number than to sit at a phone, configure it for alpha-numeric dialing, and try to dial "phone1@anydomain.com".

Yes, it’s possible to setup speed dial lists and buttons, but a phone number is also reachable (usually) from the PSTN…