port 5060 is blocked by ISP

dear
i have configured properly asterisk. At the one end i am using x-lite soft
ph and another end twinkle. call is going properly from both end but after
picking the phone not able to listen other one.
when i checked the port 5060 on the asterisk server it is always showing
closed while i have flushed all the rules from iptables (iptables -F)

PORT STATE SERVICE VERSION
5060/tcp closed sip

telnet localhost 5060 (could not connect)

8 Responses to “port 5060 is blocked by ISP”

  1. Leandro Dardini said:

    Jul 01, 12 at 3:48 am

    Port 5060 when used with the sip protocol is used witj UDP protocol. Telnet
    is using TCP.

    I am typing from my mobile phone…
    Il giorno 01/lug/2012 09:35, “alok srivastava” ha
    scritto:

  2. "B. van Ouwerkerk" said:

    Jul 01, 12 at 3:55 am

    No voice means you have to look at the rtp ports.

    You can find more via google “firewall rtp ports asterisk”

    B.

    Op 1-7-2012 9:34, alok srivastava schreef:

  3. Hans Witvliet said:

    Jul 01, 12 at 5:42 pm

    Hi Alok,

    telnet is a very crude tool to test with.
    Try hping or nmap instead.

    Hans

  4. "Olle E. Johansson" said:

    Jul 02, 12 at 3:16 am

    1 jul 2012 kl. 09:48 skrev Leandro Dardini:

    That’s not correct. SIP supports multiple transports, including TCP. Not all implementations support TCP though.

    /O

  5. Thomas Kenyon said:

    Jul 02, 12 at 7:39 am

    alok srivastava wrote:
    SIP is only used to setup (and stop etc.) the call. The actual audio is
    sent via rtp.

    /etc/asterisk/rtp.conf

    Should tell which ports asterisk is using for rtp, you will need to make
    sure that the remote host can connect to these ports.

    There are lots of articles around on how to resolve this.

  6. SamyGo said:

    Jul 02, 12 at 7:52 am

    actually its a one-way audio issue due to NAT !

    alok , please explain your network flow for end to end client-server-client.

    You may need to set nat=yes for your sip peer behind NAT. If the server is
    behind NAT router/firewall use externip= field.
    Also provide sip traces of this call.

    Another thing to do for your learning. Execute wireshark on both softphone
    systems and set “sip | rtp” as filter and see where are the RTP streams
    going on each end !

    Take a complete capture on Asterisk server by executing the command “sip
    set debug on” and make a call.

    BR
    Sammy

  7. alok srivastava said:

    Jul 04, 12 at 4:13 am

    thanks Samy i have set nat=yes, now getting sound from both side but there is too uch disturbance. soetime we becoe audible and sometime not.i did not set extern ip coz my asterisk server is directly configured on public ip. I have softphones on some where localnets separate from asterisk server campus . i also set “sip set debug on” CLI prompt. this is giving following error.

    when i test sip traffic on wireshark “401 unauthorize” error getting this error cli prompt also showing.

    my first softph(9001) is on localnet 192.168.1.136 and 2nd softphone (9000)
    in another localnet in another campus(192.168.6.25)

    Scheduling destruction of SIP dialog ‘
    551b9e744a6b41ee2c00033e22b333c0@122.160.154.189:5060′ in 32000 ms (Method:
    INVITE)
    [Jul 4 19:37:39] WARNING[3054]: chan_sip.c:3660 retrans_pkt:
    Retransmission timeout reached on transmission
    551b9e744a6b41ee2c00033e22b333c0@122.160.154.189:5060 for seqno 102
    (Critical Request) — See https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions
    Packet timed out after 32000ms with no response
    [Jul 4 19:37:39] WARNING[3054]: chan_sip.c:3689 retrans_pkt: Hanging up call 551b9e744a6b41ee2c00033e22b333c0@122.160.154.189:5060 – no reply to our critical packet (see https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions).
    — SIP/9000-00000005 is circuit-busy
    == Everyone is busy/congested at this time (1:0/1/0)
    — Auto fallthrough, channel ‘SIP/9001-00000004′ status is ‘CONGESTION’

    < --- Reliably Transmitting (NAT) to 122.163.193.94:1801 --->
    SIP/2.0 503 Service Unavailable
    Via: SIP/2.0/UDP 192.168.1.136:5060
    ;branch=z9hG4bK-d8754z-db50ccbe7eb74a0a-1—d8754z-;received2.163.193.94;rport01
    From: “9001″;tag

  8. SamyGo said:

    Jul 04, 12 at 4:41 am

    Hi,

    Being audible sometime or bad voice quality is only due to internet latency or bad internet situation.

    [Jul 4 19:37:39] WARNING[3054]: chan_sip.c:3660 retrans_pkt:
    Retransmission timeout reached on transmission
    551b9e744a6b41ee2c00033e22b333c0@122.160.154.189:5060 for seqno 102
    (Critical Request) — See https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions
    Packet timed out after 32000ms with no response
    [Jul 4 19:37:39] WARNING[3054]: chan_sip.c:3689 retrans_pkt: Hanging up call 551b9e744a6b41ee2c00033e22b333c0@122.160.154.189:5060 – no reply to our critical packet (see https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions).

    The above lines again telling that there is some problem sending sequential packets to some endpoint. That may lead to disconnection of call after some time..as it is currently doing so.

    Try setting some more NAT parameters…as you said localnet. Set
    *localnet=*parameter entries in your asterisk server sip configurations.

    BR
    Sammy