<div dir="ltr">Check your trunk @<span style="font-family:arial,sans-serif;font-size:13.333333015441895px">pstn-</span><span style="font-family:arial,sans-serif;font-size:13.333333015441895px">out there's something reaching that server 192.168.1.4?</span></div>
<div class="gmail_extra"><br><br><div class="gmail_quote">2014-04-09 12:06 GMT-05:00 Luis Eduardo Cortes <span dir="ltr"><<a href="mailto:luedcortes@gmail.com" target="_blank">luedcortes@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hello:<br>
<br>
I have this situation: I can make calls internally, I can make inbound<br>
calls but I can't make outbound calls.<br>
<br>
Thanks in advance.<br>
<br>
<br>
<br>
These are my devices:<br>
* asterisk 11.8.1 = 192.168.1.22<br>
* sipphone grandstream gxp2160 = 192.168.1.5<br>
* gateway audiocodes mp-114 2fxs-2fxo = 192.168.1.4<br>
port 1 (FXS) connected to an analog phone<br>
port 3 (FXO) connected to the PSTN<br>
<br>
These are my sip.conf and extensions.conf files:<br>
<br>
sip.conf<br>
--------<br>
[general]<br>
context = incoming-call<br>
allowguest = no<br>
srvlookup = no<br>
udpbindaddr = 0.0.0.0<br>
tcpenable = no<br>
qualify = yes<br>
language = es<br>
<br>
[office](!)<br>
type = friend<br>
context = internal-call<br>
host = dynamic<br>
nat = force_rport,comedia<br>
dtmfmode = auto<br>
disallow = all<br>
allow = g722<br>
allow = alaw<br>
allow = ulaw<br>
<br>
[telefono](office)<br>
description = grandstream gxp2160<br>
secret = telefono<br>
<br>
[celular](office)<br>
description = samsung gt-s7562<br>
secret = celular<br>
<br>
[fxs](office)<br>
description = fxs port1<br>
secret = fxs<br>
<br>
[pstn](!)<br>
nat = no<br>
canreinvite = no<br>
dtmfmode = auto<br>
disallow = all<br>
allow = g722<br>
allow = alaw<br>
allow = ulaw<br>
<br>
[pstn-in](pstn)<br>
description = pstn-in port3<br>
type = user<br>
host = dynamic<br>
secret = pstn-in<br>
context = incoming-call<br>
<br>
[pstn-out](pstn)<br>
description = pstn-out port3<br>
type = peer<br>
host = 192.168.1.4<br>
<br>
extensions.conf<br>
---------------<br>
[incoming-call]<br>
exten => _24872006,1,Answer()<br>
same => n,Dial(SIP/telefono)<br>
same => n,Hangup()<br>
<br>
[outgoing-call]<br>
exten => _X.,1,Dial(SIP/${EXTEN}@pstn-out)<br>
<br>
[internal-call]<br>
exten => 101,1,Dial(SIP/telefono)<br>
exten => 102,1,Dial(SIP/celular)<br>
exten => 103,1,Dial(SIP/fxs)<br>
exten => 104,1,Answer()<br>
same => n,Playback(tt-weasels)<br>
same => n,Hangup()<br>
include => outgoing-call<br>
<br>
This is the result of "sip show peers"<br>
--------------------------------------<br>
Name/username Host Dyn Forcerport Comedia ACL Port<br>
Status Description<br>
celular/celular 192.168.1.21 D Yes Yes<br>
47747 OK (6 ms) samsung gt-s7562<br>
fxs/fxs 192.168.1.4 D Yes Yes 5060<br>
OK (27 ms) fxs port1<br>
pstn-out 192.168.1.4 No No 5060<br>
OK (25 ms) pstn-out port3<br>
telefono/telefono 192.168.1.5 D Yes Yes 1555<br>
OK (3 ms) grandstream gxp2160<br>
4 sip peers [Monitored: 4 online, 0 offline Unmonitored: 0 online, 0 offline]<br>
<br>
This is the result of "sip show users"<br>
--------------------------------------<br>
Username Secret Accountcode Def.Context ACL Forcerport<br>
celular celular internal-call No Yes<br>
pstn-in pstn-in incoming-call No No<br>
fxs fxs internal-call No Yes<br>
telefono telefono internal-call No Yes<br>
debian-asterisk*CLI><br>
<br>
This is the result of "sip set debug on" when I try to make an outbound call:<br>
----------------------------------------------------------------------------<br>
<--- SIP read from UDP:<a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
INVITE <a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.5:1555;branch=z9hG4bK2009427179;rport<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>><br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 30 INVITE<br>
Contact: <<a href="http://sip:telefono@192.168.1.5:1555" target="_blank">sip:telefono@192.168.1.5:1555</a>><br>
X-Grandstream-PBX: true<br>
Max-Forwards: 70<br>
User-Agent: Grandstream GXP2160 1.0.0.17<br>
Privacy: none<br>
P-Preferred-Identity: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>><br>
Supported: replaces, path, timer<br>
Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO,<br>
REFER, UPDATE, MESSAGE<br>
Content-Type: application/sdp<br>
Accept: application/sdp, application/dtmf-relay<br>
Content-Length: 335<br>
<br>
v=0<br>
o=telefono 8000 8000 IN IP4 192.168.1.5<br>
s=SIP Call<br>
c=IN IP4 192.168.1.5<br>
t=0 0<br>
m=audio 5004 RTP/AVP 0 8 18 9 2 101<br>
a=sendrecv<br>
a=rtpmap:0 PCMU/8000<br>
a=ptime:20<br>
a=rtpmap:8 PCMA/8000<br>
a=rtpmap:18 G729/8000<br>
a=fmtp:18 annexb=no<br>
a=rtpmap:9 G722/8000<br>
a=rtpmap:2 G726-32/8000<br>
a=rtpmap:101 telephone-event/8000<br>
a=fmtp:101 0-15<br>
<-------------><br>
--- (17 headers 16 lines) ---<br>
Sending to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> (no NAT)<br>
Sending to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> (no NAT)<br>
Using INVITE request as basis request - 667168938-1555-4@BJC.BGI.B.F<br>
Found peer 'telefono' for 'telefono' from <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a><br>
<br>
<--- Reliably Transmitting (NAT) to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
SIP/2.0 401 Unauthorized<br>
Via: SIP/2.0/UDP<br>
192.168.1.5:1555;branch=z9hG4bK2009427179;received=192.168.1.5;rport=1555<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>>;tag=as50d1512e<br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 30 INVITE<br>
Server: Asterisk PBX 11.8.1<br>
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY,<br>
INFO, PUBLISH<br>
Supported: replaces, timer<br>
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="1032f9e6"<br>
Content-Length: 0<br>
<br>
<br>
<------------><br>
Scheduling destruction of SIP dialog '667168938-1555-4@BJC.BGI.B.F' in<br>
6400 ms (Method: INVITE)<br>
<br>
<--- SIP read from UDP:<a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
ACK <a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.5:1555;branch=z9hG4bK2009427179;rport<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>>;tag=as50d1512e<br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 30 ACK<br>
Content-Length: 0<br>
<br>
<-------------><br>
--- (7 headers 0 lines) ---<br>
<br>
<--- SIP read from UDP:<a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
INVITE <a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.5:1555;branch=z9hG4bK415263616;rport<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>><br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 31 INVITE<br>
Contact: <<a href="http://sip:telefono@192.168.1.5:1555" target="_blank">sip:telefono@192.168.1.5:1555</a>><br>
Authorization: Digest username="telefono", realm="asterisk",<br>
nonce="1032f9e6", uri="<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>",<br>
response="491072c64fd264bd28d0ac088a738dc3", algorithm=MD5<br>
X-Grandstream-PBX: true<br>
Max-Forwards: 70<br>
User-Agent: Grandstream GXP2160 1.0.0.17<br>
Privacy: none<br>
P-Preferred-Identity: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>><br>
Supported: replaces, path, timer<br>
Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO,<br>
REFER, UPDATE, MESSAGE<br>
Content-Type: application/sdp<br>
Accept: application/sdp, application/dtmf-relay<br>
Content-Length: 335<br>
<br>
v=0<br>
o=telefono 8000 8000 IN IP4 192.168.1.5<br>
s=SIP Call<br>
c=IN IP4 192.168.1.5<br>
t=0 0<br>
m=audio 5004 RTP/AVP 0 8 18 9 2 101<br>
a=sendrecv<br>
a=rtpmap:0 PCMU/8000<br>
a=ptime:20<br>
a=rtpmap:8 PCMA/8000<br>
a=rtpmap:18 G729/8000<br>
a=fmtp:18 annexb=no<br>
a=rtpmap:9 G722/8000<br>
a=rtpmap:2 G726-32/8000<br>
a=rtpmap:101 telephone-event/8000<br>
a=fmtp:101 0-15<br>
<-------------><br>
--- (18 headers 16 lines) ---<br>
Sending to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> (NAT)<br>
Using INVITE request as basis request - 667168938-1555-4@BJC.BGI.B.F<br>
Found peer 'telefono' for 'telefono' from <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a><br>
== Using SIP RTP CoS mark 5<br>
Found RTP audio format 0<br>
Found RTP audio format 8<br>
Found RTP audio format 18<br>
Found RTP audio format 9<br>
Found RTP audio format 2<br>
Found RTP audio format 101<br>
Found audio description format PCMU for ID 0<br>
Found audio description format PCMA for ID 8<br>
Found audio description format G729 for ID 18<br>
Found audio description format G722 for ID 9<br>
Found audio description format G726-32 for ID 2<br>
Found audio description format telephone-event for ID 101<br>
Capabilities: us - (ulaw|alaw|g722), peer -<br>
audio=(ulaw|alaw|g726|g729|g722)/video=(nothing)/text=(nothing),<br>
combined - (ulaw|alaw|g722)<br>
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1<br>
(telephone-event|), combined - 0x1 (telephone-event|)<br>
Peer audio RTP is at port <a href="http://192.168.1.5:5004" target="_blank">192.168.1.5:5004</a><br>
Looking for 22222222 in internal-call (domain 192.168.1.22)<br>
list_route: hop: <<a href="http://sip:telefono@192.168.1.5:1555" target="_blank">sip:telefono@192.168.1.5:1555</a>><br>
<br>
<--- Transmitting (NAT) to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
SIP/2.0 100 Trying<br>
Via: SIP/2.0/UDP<br>
192.168.1.5:1555;branch=z9hG4bK415263616;received=192.168.1.5;rport=1555<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>><br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 31 INVITE<br>
Server: Asterisk PBX 11.8.1<br>
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY,<br>
INFO, PUBLISH<br>
Supported: replaces, timer<br>
Session-Expires: 1800;refresher=uas<br>
Contact: <<a href="http://sip:22222222@192.168.1.22:5060" target="_blank">sip:22222222@192.168.1.22:5060</a>><br>
Content-Length: 0<br>
<br>
<br>
<------------><br>
-- Executing [22222222@internal-call:1]<br>
Dial("SIP/telefono-00000004", "SIP/22222222@pstn-out") in new stack<br>
== Using SIP RTP CoS mark 5<br>
Audio is at 29272<br>
Adding codec 100012 (g722) to SDP<br>
Adding codec 100004 (alaw) to SDP<br>
Adding codec 100003 (ulaw) to SDP<br>
Adding non-codec 0x1 (telephone-event) to SDP<br>
Reliably Transmitting (no NAT) to <a href="http://192.168.1.4:5060" target="_blank">192.168.1.4:5060</a>:<br>
INVITE <a href="mailto:sip%3A22222222@192.168.1.4">sip:22222222@192.168.1.4</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.22:5060;branch=z9hG4bK3f81cf2e<br>
Max-Forwards: 70<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=as7cd8ea4c<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.4">sip:22222222@192.168.1.4</a>><br>
Contact: <<a href="http://sip:telefono@192.168.1.22:5060" target="_blank">sip:telefono@192.168.1.22:5060</a>><br>
Call-ID: <a href="http://323866b71557eac419f667ee37ee16ae@192.168.1.22:5060" target="_blank">323866b71557eac419f667ee37ee16ae@192.168.1.22:5060</a><br>
CSeq: 102 INVITE<br>
User-Agent: Asterisk PBX 11.8.1<br>
Date: Wed, 09 Apr 2014 15:00:11 GMT<br>
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY,<br>
INFO, PUBLISH<br>
Supported: replaces, timer<br>
Content-Type: application/sdp<br>
Content-Length: 281<br>
<br>
v=0<br>
o=root 268828888 268828888 IN IP4 192.168.1.22<br>
s=Asterisk PBX 11.8.1<br>
c=IN IP4 192.168.1.22<br>
t=0 0<br>
m=audio 29272 RTP/AVP 9 8 0 101<br>
a=rtpmap:9 G722/8000<br>
a=rtpmap:8 PCMA/8000<br>
a=rtpmap:0 PCMU/8000<br>
a=rtpmap:101 telephone-event/8000<br>
a=fmtp:101 0-16<br>
a=ptime:20<br>
a=sendrecv<br>
<br>
---<br>
-- Called SIP/22222222@pstn-out<br>
<br>
<--- SIP read from UDP:<a href="http://192.168.1.4:5060" target="_blank">192.168.1.4:5060</a> ---><br>
SIP/2.0 404 Not Found<br>
Via: SIP/2.0/UDP 192.168.1.22:5060;branch=z9hG4bK3f81cf2e<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=as7cd8ea4c<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.4">sip:22222222@192.168.1.4</a>>;tag=1c1296932060<br>
Call-ID: <a href="http://323866b71557eac419f667ee37ee16ae@192.168.1.22:5060" target="_blank">323866b71557eac419f667ee37ee16ae@192.168.1.22:5060</a><br>
CSeq: 102 INVITE<br>
Allow: REGISTER,OPTIONS,INVITE,ACK,CANCEL,BYE,NOTIFY,PRACK,REFER,INFO,SUBSCRIBE,UPDATE<br>
Server: MP-114 FXS_FXO/v.6.60A.041.005<br>
Reason: Q.850 ;cause=3 ;text="local"<br>
Content-Length: 0<br>
<br>
<-------------><br>
--- (10 headers 0 lines) ---<br>
Transmitting (no NAT) to <a href="http://192.168.1.4:5060" target="_blank">192.168.1.4:5060</a>:<br>
ACK <a href="mailto:sip%3A22222222@192.168.1.4">sip:22222222@192.168.1.4</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.22:5060;branch=z9hG4bK3f81cf2e<br>
Max-Forwards: 70<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=as7cd8ea4c<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.4">sip:22222222@192.168.1.4</a>>;tag=1c1296932060<br>
Contact: <<a href="http://sip:telefono@192.168.1.22:5060" target="_blank">sip:telefono@192.168.1.22:5060</a>><br>
Call-ID: <a href="http://323866b71557eac419f667ee37ee16ae@192.168.1.22:5060" target="_blank">323866b71557eac419f667ee37ee16ae@192.168.1.22:5060</a><br>
CSeq: 102 ACK<br>
User-Agent: Asterisk PBX 11.8.1<br>
Content-Length: 0<br>
<br>
<br>
---<br>
Scheduling destruction of SIP dialog<br>
'<a href="http://323866b71557eac419f667ee37ee16ae@192.168.1.22:5060" target="_blank">323866b71557eac419f667ee37ee16ae@192.168.1.22:5060</a>' in 6400 ms<br>
(Method: INVITE)<br>
== Everyone is busy/congested at this time (1:0/0/1)<br>
-- Auto fallthrough, channel 'SIP/telefono-00000004' status is 'CHANUNAVAIL'<br>
<br>
<--- Reliably Transmitting (NAT) to <a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
SIP/2.0 503 Service Unavailable<br>
Via: SIP/2.0/UDP<br>
192.168.1.5:1555;branch=z9hG4bK415263616;received=192.168.1.5;rport=1555<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>>;tag=as4caf91d6<br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 31 INVITE<br>
Server: Asterisk PBX 11.8.1<br>
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY,<br>
INFO, PUBLISH<br>
Supported: replaces, timer<br>
Session-Expires: 1800;refresher=uas<br>
X-Asterisk-HangupCause: Unallocated (unassigned) number<br>
X-Asterisk-HangupCauseCode: 1<br>
Content-Length: 0<br>
<br>
<br>
<------------><br>
<br>
<--- SIP read from UDP:<a href="http://192.168.1.5:1555" target="_blank">192.168.1.5:1555</a> ---><br>
ACK <a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a> SIP/2.0<br>
Via: SIP/2.0/UDP 192.168.1.5:1555;branch=z9hG4bK415263616;rport<br>
From: <<a href="mailto:sip%3Atelefono@192.168.1.22">sip:telefono@192.168.1.22</a>>;tag=1524540678<br>
To: <<a href="mailto:sip%3A22222222@192.168.1.22">sip:22222222@192.168.1.22</a>>;tag=as4caf91d6<br>
Call-ID: 667168938-1555-4@BJC.BGI.B.F<br>
CSeq: 31 ACK<br>
Content-Length: 0<br>
<br>
<-------------><br>
--- (7 headers 0 lines) ---<br>
Really destroying SIP dialog '667168938-1555-4@BJC.BGI.B.F' Method: ACK<br>
debian-asterisk*CLI> sip set debug off<br>
SIP Debugging Disabled<br>
debian-asterisk*CLI><br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
<br>
<br>
--<br>
Usuario Linux Registrado # 342019<br>
--> <a href="http://linuxcounter.net/" target="_blank">http://linuxcounter.net/</a> <--<br>
skype --> luedcortes<br>
gtalk --> <a href="mailto:luedcortes@gmail.com">luedcortes@gmail.com</a><br>
msn --> <a href="mailto:luedcortes@gmail.com">luedcortes@gmail.com</a><br>
<br>
--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div><img src="http://ccg.com.pe/firmas/firmaccg-gustavo.png"><br></div>
</div>