<p>Is your box behind Nat? Try to play with ext-rtp-ip and ext-sip-ip for external profile.</p>
<div class="gmail_quote">28.04.2012 12:02 пользователь &quot;Anton Kvashenkin&quot; &lt;<a href="mailto:anton.jugatsu@gmail.com">anton.jugatsu@gmail.com</a>&gt; написал:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_extra">What do use for PSTN termination? VOIP-gateway or just sip trunk? Show your dialplan for outgoing to PSTN.<br><br><div class="gmail_quote">28 апреля 2012 г. 0:29 пользователь Alfred Ahuta <span dir="ltr">&lt;<a href="mailto:aahuta@gmail.com" target="_blank">aahuta@gmail.com</a>&gt;</span> написал:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I&#39;m experiencing No Audio when i call pstn from an extension mapped to X-lite. internal sip endpoints i&#39;m able to establish 2 way audio<br>

but not when i call out. i&#39;m able to establish connection without the audio though.<br>
<br>below is my debug log<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:4918 Audio Codec Compare [PCMU:0:8000:20:64000]/[PCMU:0:8000:20:64000]<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:3017 Set Codec sofia/external/18178455922 PCMU/8000 20 ms 160 samples 64000 bits<br>


2012-04-27 12:57:13.533748 [DEBUG] switch_core_codec.c:111 sofia/external/18178455922 Original read codec set to PCMU:0<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:5032 Set 2833 dtmf send payload to 101<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:3269 AUDIO RTP [sofia/external/18178455922] XX.XXX.XX.149 port 26586 -&gt; 67.215.226.150 port 19474 codec: 0 ms: 20<br>


2012-04-27 12:57:13.533748 [DEBUG] switch_rtp.c:1661 Starting timer [soft] 160 bytes per 20ms<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:3533 Set 2833 dtmf send payload to 101<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:3539 Set 2833 dtmf receive payload to 101<br>


2012-04-27 12:57:13.533748 [NOTICE] sofia_glue.c:4063 Pre-Answer sofia/external/18178455922!<br>2012-04-27 12:57:13.533748 [DEBUG] switch_channel.c:2986 (sofia/external/18178455922) Callstate Change RINGING -&gt; EARLY<br>


2012-04-27 12:57:13.533748 [INFO] switch_ivr_originate.c:3215 Sending early media<br>2012-04-27 12:57:13.533748 [DEBUG] sofia_glue.c:3269 AUDIO RTP [sofia/internal/1000@XX.XXX.XX.149:5080] XX.XXX.XX.149 port 22578 -&gt; 76.187.91.204 port 40032 codec: 0 ms: 20<br>


2012-04-27 12:57:13.533748 [DEBUG] switch_rtp.c:1661 Starting timer [soft] 160 bytes per 20ms<br>2012-04-27 12:57:13.553797 [DEBUG] sofia_glue.c:3533 Set 2833 dtmf send payload to 101<br>2012-04-27 12:57:13.553797 [DEBUG] sofia_glue.c:3539 Set 2833 dtmf receive payload to 101<br>


2012-04-27 12:57:13.553797 [DEBUG] mod_sofia.c:2582 Ring SDP:<br>v=0<br>o=FreeSWITCH 1335523255 1335523256 IN IP4 XX.XXX.XX.149<br>s=FreeSWITCH<br>c=IN IP4 XX.XXX.XX.149<br>t=0 0<br>m=audio 22578 RTP/AVP 0 101<br>a=rtpmap:0 PCMU/8000<br>


a=rtpmap:101 telephone-event/8000<br>a=fmtp:101 0-16<br>a=silenceSupp:off - - - -<br>a=ptime:20<br>a=sendrecv<br><br>o=root 2889 2889 IN IP4 67.215.226.150<br>s=session<br>c=IN IP4 67.215.226.150<br>t=0 0<br>m=audio 12116 RTP/AVP 0 8 101<br>


a=rtpmap:0 PCMU/8000<br>a=rtpmap:8 PCMA/8000<br>a=rtpmap:101 telephone-event/8000<br>a=fmtp:101 0-16<br>a=ptime:20<br><br><br><br><br><br><br>2012-04-27 12:57:13.553797 [NOTICE] mod_sofia.c:2585 Pre-Answer sofia/internal/1000@XX.XXX.XX.149:5080!<br>


2012-04-27 12:57:13.553797 [DEBUG] switch_channel.c:2986 (sofia/internal/1000@XX.XXX.XX.149:5080) Callstate Change RINGING -&gt; EARLY<br>2012-04-27 12:57:13.553797 [DEBUG] switch_channel.c:3028 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:13.553797 [DEBUG] switch_core_session.c:877 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:13.553797 [DEBUG] sofia.c:5554 Channel sofia/internal/1000@XX.XXX.XX.149:5080 skipping state [early][183]<br>


2012-04-27 12:57:13.553797 [DEBUG] switch_core_session.c:731 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:13.553797 [DEBUG] switch_ivr_originate.c:3266 Originate Resulted in Success: [sofia/external/18178455922]<br>


2012-04-27 12:57:13.573784 [DEBUG] switch_core_session.c:731 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:13.573784 [DEBUG] switch_core_session.c:731 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:13.573784 [DEBUG] switch_ivr_bridge.c:1331 (sofia/external/18178455922) State Change CS_CONSUME_MEDIA -&gt; CS_EXCHANGE_MEDIA<br>2012-04-27 12:57:13.573784 [DEBUG] switch_core_state_machine.c:362 (sofia/external/18178455922) Running State Change CS_EXCHANGE_MEDIA<br>


2012-04-27 12:57:13.573784 [DEBUG] switch_core_session.c:1182 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:13.573784 [DEBUG] switch_core_state_machine.c:420 (sofia/external/18178455922) State EXCHANGE_MEDIA<br>


2012-04-27 12:57:13.573784 [DEBUG] mod_sofia.c:582 SOFIA EXCHANGE_MEDIA<br>2012-04-27 12:57:17.493751 [DEBUG] switch_core_session.c:877 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:17.493751 [DEBUG] switch_core_session.c:877 Send signal sofia/external/18178455922 [BREAK]<br>


2012-04-27 12:57:17.513750 [DEBUG] sofia.c:5561 Channel sofia/external/18178455922 entering state [completing][200]<br>2012-04-27 12:57:17.513750 [DEBUG] sofia.c:5572 Remote SDP:<br>v=0<br>o=root 2889 2890 IN IP4 67.215.226.150<br>


s=session<br>c=IN IP4 67.215.226.150<br>t=0 0<br>m=audio 19474 RTP/AVP 0 8 101<br>a=rtpmap:0 PCMU/8000<br>a=rtpmap:8 PCMA/8000<br>a=rtpmap:101 telephone-event/8000<br>a=fmtp:101 0-16<br>a=ptime:20<br><br>2012-04-27 12:57:17.513750 [DEBUG] switch_core_session.c:877 Send signal sofia/external/18178455922 [BREAK]<br>


2012-04-27 12:57:17.513750 [DEBUG] switch_core_session.c:877 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:17.513750 [DEBUG] sofia.c:5561 Channel sofia/external/18178455922 entering state [ready][200]<br>


2012-04-27 12:57:17.513750 [DEBUG] switch_channel.c:3245 (sofia/external/18178455922) Callstate Change EARLY -&gt; ACTIVE<br>2012-04-27 12:57:17.513750 [DEBUG] switch_channel.c:3257 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:17.513750 [NOTICE] sofia.c:6214 Channel [sofia/external/18178455922] has been answered<br>2012-04-27 12:57:17.533751 [DEBUG] mod_sofia.c:754 Local SDP sofia/internal/1000@XX.XXX.XX.149:5080:<br>v=0<br>o=FreeSWITCH 1335523255 1335523257 IN IP4 XX.XXX.XX.149<br>


s=FreeSWITCH<br>c=IN IP4 XX.XXX.XX.149<br>t=0 0<br>m=audio 22578 RTP/AVP 0 101<br>a=rtpmap:0 PCMU/8000<br>a=rtpmap:101 telephone-event/8000<br>a=fmtp:101 0-16<br>a=silenceSupp:off - - - -<br>a=ptime:20<br>a=sendrecv<br><br>


2012-04-27 12:57:17.533751 [DEBUG] switch_core_session.c:877 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:17.533751 [DEBUG] sofia.c:5561 Channel sofia/internal/1000@XX.XXX.XX.149:5080 entering state [completed][200]<br>


2012-04-27 12:57:17.533751 [DEBUG] switch_core_session.c:731 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:17.533751 [DEBUG] switch_channel.c:3245 (sofia/internal/1000@XX.XXX.XX.149:5080) Callstate Change EARLY -&gt; ACTIVE<br>


2012-04-27 12:57:17.533751 [NOTICE] switch_ivr_bridge.c:417 Channel [sofia/internal/1000@XX.XXX.XX.149:5080] has been answered<br>2012-04-27 12:57:17.693753 [DEBUG] switch_core_session.c:877 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:17.693753 [DEBUG] switch_core_session.c:877 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:17.693753 [DEBUG] switch_core_session.c:877 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:17.713754 [DEBUG] sofia.c:5561 Channel sofia/internal/1000@XX.XXX.XX.149:5080 entering state [ready][200]<br>2012-04-27 12:57:17.713754 [DEBUG] switch_core_session.c:793 Send signal sofia/external/18178455922 [BREAK]<br>


2012-04-27 12:57:17.713754 [DEBUG] switch_core_session.c:793 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:24.913748 [DEBUG] switch_core_session.c:877 Send signal sofia/external/18178455922 [BREAK]<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_channel.c:2849 (sofia/external/18178455922) Callstate Change ACTIVE -&gt; HANGUP<br>2012-04-27 12:57:24.933750 [NOTICE] sofia.c:636 Hangup sofia/external/18178455922 [CS_EXCHANGE_MEDIA] [NORMAL_CLEARING]<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_channel.c:2872 Send signal sofia/external/18178455922 [KILL]<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_session.c:1182 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:24.933750 [DEBUG] switch_ivr_bridge.c:586 BRIDGE THREAD DONE [sofia/external/18178455922]<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_ivr_bridge.c:611 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:420 (sofia/external/18178455922) State EXCHANGE_MEDIA going to sleep<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:362 (sofia/external/18178455922) Running State Change CS_HANGUP<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:602 (sofia/external/18178455922) State HANGUP<br>


2012-04-27 12:57:24.933750 [DEBUG] mod_sofia.c:469 Channel sofia/external/18178455922 hanging up, cause: NORMAL_CLEARING<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:47 sofia/external/18178455922 Standard HANGUP, cause: NORMAL_CLEARING<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:602 (sofia/external/18178455922) State HANGUP going to sleep<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:393 (sofia/external/18178455922) State Change CS_HANGUP -&gt; CS_REPORTING<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_session.c:1182 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:362 (sofia/external/18178455922) Running State Change CS_REPORTING<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:662 (sofia/external/18178455922) State REPORTING<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:79 sofia/external/18178455922 Standard REPORTING, cause: NORMAL_CLEARING<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:662 (sofia/external/18178455922) State REPORTING going to sleep<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_state_machine.c:387 (sofia/external/18178455922) State Change CS_REPORTING -&gt; CS_DESTROY<br>


2012-04-27 12:57:24.933750 [DEBUG] switch_core_session.c:1182 Send signal sofia/external/18178455922 [BREAK]<br>2012-04-27 12:57:24.933750 [DEBUG] switch_core_session.c:1382 Session 205 (sofia/external/18178455922) Locked, Waiting on external entities<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_ivr_bridge.c:586 BRIDGE THREAD DONE [sofia/internal/1000@XX.XXX.XX.149:5080]<br>2012-04-27 12:57:24.954657 [DEBUG] switch_ivr_bridge.c:611 Send signal sofia/external/18178455922 [BREAK]<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_session.c:731 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:24.954657 [NOTICE] switch_core_state_machine.c:226 sofia/internal/1000@XX.XXX.XX.149:5080 has executed the last dialplan instruction, hanging up.<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_channel.c:2849 (sofia/internal/1000@XX.XXX.XX.149:5080) Callstate Change ACTIVE -&gt; HANGUP<br>2012-04-27 12:57:24.954657 [NOTICE] switch_core_state_machine.c:228 Hangup sofia/internal/1000@XX.XXX.XX.149:5080 [CS_EXECUTE] [NORMAL_CLEARING]<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_channel.c:2872 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [KILL]<br>2012-04-27 12:57:24.954657 [DEBUG] switch_core_session.c:1182 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:417 (sofia/internal/1000@XX.XXX.XX.149:5080) State EXECUTE going to sleep<br>2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:362 (sofia/internal/1000@XX.XXX.XX.149:5080) Running State Change CS_HANGUP<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:602 (sofia/internal/1000@XX.XXX.XX.149:5080) State HANGUP<br>2012-04-27 12:57:24.954657 [DEBUG] mod_sofia.c:463 sofia/internal/1000@XX.XXX.XX.149:5080 Overriding SIP cause 480 with 200 from the other leg<br>


2012-04-27 12:57:24.954657 [DEBUG] mod_sofia.c:469 Channel sofia/internal/1000@XX.XXX.XX.149:5080 hanging up, cause: NORMAL_CLEARING<br>2012-04-27 12:57:24.954657 [DEBUG] mod_sofia.c:517 Sending BYE to sofia/internal/1000@XX.XXX.XX.149:5080<br>


2012-04-27 12:57:24.954657 [NOTICE] switch_core_session.c:1400 Session 205 (sofia/external/18178455922) Ended<br>2012-04-27 12:57:24.954657 [NOTICE] switch_core_session.c:1402 Close Channel sofia/external/18178455922 [CS_DESTROY]<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:491 (sofia/external/18178455922) Callstate Change HANGUP -&gt; DOWN<br>2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:494 (sofia/external/18178455922) Running State Change CS_DESTROY<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:504 (sofia/external/18178455922) State DESTROY<br>2012-04-27 12:57:24.954657 [DEBUG] mod_sofia.c:374 sofia/external/18178455922 SOFIA DESTROY<br>2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:86 sofia/external/18178455922 Standard DESTROY<br>


2012-04-27 12:57:24.954657 [DEBUG] switch_core_state_machine.c:504 (sofia/external/18178455922) State DESTROY going to sleep<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:47 sofia/internal/1000@XX.XXX.XX.149:5080 Standard HANGUP, cause: NORMAL_CLEARING<br>


2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:602 (sofia/internal/1000@XX.XXX.XX.149:5080) State HANGUP going to sleep<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:393 (sofia/internal/1000@XX.XXX.XX.149:5080) State Change CS_HANGUP -&gt; CS_REPORTING<br>


2012-04-27 12:57:24.973781 [DEBUG] switch_core_session.c:1182 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:362 (sofia/internal/1000@XX.XXX.XX.149:5080) Running State Change CS_REPORTING<br>


2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:662 (sofia/internal/1000@XX.XXX.XX.149:5080) State REPORTING<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:79 sofia/internal/1000@XX.XXX.XX.149:5080 Standard REPORTING, cause: NORMAL_CLEARING<br>


2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:662 (sofia/internal/1000@XX.XXX.XX.149:5080) State REPORTING going to sleep<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_state_machine.c:387 (sofia/internal/1000@XX.XXX.XX.149:5080) State Change CS_REPORTING -&gt; CS_DESTROY<br>


2012-04-27 12:57:24.973781 [DEBUG] switch_core_session.c:1182 Send signal sofia/internal/1000@XX.XXX.XX.149:5080 [BREAK]<br>2012-04-27 12:57:24.973781 [DEBUG] switch_core_session.c:1382 Session 204 (sofia/internal/1000@XX.XXX.XX.149:5080) Locked, Waiting on external entities<br>


2012-04-27 12:57:24.973781 [NOTICE] switch_core_session.c:1400 Session 204 (sofia/internal/1000@XX.XXX.XX.149:5080) Ended<br>2012-04-27 12:57:24.995020 [NOTICE] switch_core_session.c:1402 Close Channel sofia/internal/1000@XX.XXX.XX.149:5080 [CS_DESTROY]<br>


2012-04-27 12:57:24.995020 [DEBUG] switch_core_state_machine.c:491 (sofia/internal/1000@XX.XXX.XX.149:5080) Callstate Change HANGUP -&gt; DOWN<br>2012-04-27 12:57:24.995020 [DEBUG] switch_core_state_machine.c:494 (sofia/internal/1000@XX.XXX.XX.149:5080) Running State Change CS_DESTROY<br>


2012-04-27 12:57:24.995020 [DEBUG] switch_core_state_machine.c:504 (sofia/internal/1000@XX.XXX.XX.149:5080) State DESTROY<br>2012-04-27 12:57:24.995020 [DEBUG] mod_sofia.c:374 sofia/internal/1000@XX.XXX.XX.149:5080 SOFIA DESTROY<br>


2012-04-27 12:57:24.995020 [DEBUG] switch_core_state_machine.c:86 sofia/internal/1000@XX.XXX.XX.149:5080 Standard DESTROY<br>2012-04-27 12:57:24.995020 [DEBUG] switch_core_state_machine.c:504 (sofia/internal/1000@XX.XXX.XX.149:5080) State DESTROY going to sleep<span><font color="#888888"><br>


<br><br>Alfred<br><br>
</font></span><br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br></div>
</blockquote></div>