Cursos Asterisk en México

Llamada se desconecta

Colapsar

Anuncio

Colapsar
No hay anuncio todavía.
X
 
  • Filtrar
  • Tiempo
  • Mostrar
Limpiar Todo
nuevos mensajes

  • Llamada se desconecta

    Que tal
    Tengo un servidor asterisk detras de un ruteador cisco serie 1800, hice un NAT en el ruteador para cambiar el puerto de conexion todo el trafico que llegue por el puerto que yo elegi lo mando al 5060 interno al asterisk (en el telefono solo especifico el puerto X.X.X.X:PUERTO) , de esta manera reduzco el riego de ser hackeado ya que rastrean el trafico del 5060, el detalle es que quiero conectar extensiones remotas, y puedo conectarlas satisfactoriamente pero en 10 segundos la llamada se corta, les muestro mi configuracion a ver si alguien tiene una idea de como solucionar esto.

    [general]
    context=CONTEXTO
    allowoverlap=no
    nat=yes
    externip=70.45.30.2 <---------(FALSA)
    localnet=192.168.0.0/255.255.255.0



    [usuarioremoto]
    Type = peer
    Username = usuarioremoto
    Secret = password
    canreinvite=no
    Qualify=yes
    Host = dynamic
    Context = phones

  • #2
    Re: Llamada se desconecta

    comienza poniendo la ip genuina y no falsa , y veo que el usuario creado no pones el nat=yes prueba con eso , si no te funciona pon aqui el debug para ver que pasa cuando se corta , pero esto huele a NAT!!

    Comentario


    • #3
      Re: Llamada se desconecta

      Aqui te va el debug.
      usando esta configuracion en sip.conf
      -----------------------------------------
      [general]
      context=CCSIMURPHY
      allowoverlap=no
      nat=yes
      externip=71.169.54.213
      localnet=0.0.0.0/255.255.255.0

      [test.user.mob]
      Type = peer
      Username = test.user.mob
      Secret = secret
      nat=yes
      port:6512
      canreinvite=very
      Qualify=yes
      Host = dynamic
      Context = phones

      [test.user2.mob]
      Type = peer
      Username = test.user.mob
      Secret = secret
      nat=yes
      port:6512
      canreinvite=very
      Qualify=yes
      Host = dynamic
      Context = phones
      --------------------------------------------------------------------------------------------------------



      WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="66c6bcb4"
      Content-Length: 0


      <------------>
      Scheduling destruction of SIP dialog 'ZmRmYzVlZmI0NDZiZTU4N2E5MWUzYjE2ZTY5Mzk0MmE.' in 32000 ms (Method: REGISTER)

      <--- SIP read from UDP:187.184.21.19:41846 --->
      REGISTER sip:71.169.54.213:6512 SIP/2.0
      Via: SIP/2.0/UDP 192.168.1.109:41846;branch=z9hG4bK-d8754z-6fbbdd0d41f89eed-1---d8754z-;rport
      Max-Forwards: 70
      Contact: <sip:test.user.mob@187.184.21.19:41846;transport=u dp;rinstance=c430d07101cb7f28>
      To: <sip:test.user.mob@71.169.54.213:6512>
      From: <sip:test.user.mob@71.169.54.213:6512>;tag=687347f e
      Call-ID: ZmRmYzVlZmI0NDZiZTU4N2E5MWUzYjE2ZTY5Mzk0MmE.
      CSeq: 12 REGISTER
      Expires: 3600
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
      User-Agent: X-Lite 4 release 4.1 stamp 63214
      Authorization: Digest username="test.user.mob",realm="asterisk",nonce="6 6c6bcb4",uri="sip:71.169.54.213:6512",response="56 a4a01926bb5bff732bd2fc7e543051",algorithm=MD5
      Content-Length: 0


      <------------->
      --- (13 headers 0 lines) ---
      Sending to 187.184.21.19 : 41846 (NAT)
      Reliably Transmitting (NAT) to 187.184.21.19:41846:
      OPTIONS sip:test.user.mob@187.184.21.19:41846;transport=ud p;rinstance=c430d07101cb7f28 SIP/2.0
      Via: SIP/2.0/UDP 192.168.0.16:6512;branch=z9hG4bK5e0c85d4;rport
      Max-Forwards: 70
      From: "asterisk" <sip:asterisk@192.168.0.16:6512>;tag=as43e9ccbd
      To: <sip:test.user.mob@187.184.21.19:41846;transport=u dp;rinstance=c430d07101cb7f28>
      Contact: <sip:asterisk@192.168.0.16:6512>
      Call-ID: 516e4a591fa261ab2a90138448ddcee3@192.168.0.16
      CSeq: 102 OPTIONS
      User-Agent: Asterisk PBX 1.6.2.20
      Date: Thu, 01 Dec 2011 01:20:09 GMT
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
      Supported: replaces, timer
      Content-Length: 0


      ---

      <--- Transmitting (NAT) to 187.184.21.19:41846 --->
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.1.109:41846;branch=z9hG4bK-d8754z-6fbbdd0d41f89eed-1---d8754z-;received=187.184.21.19;rport=41846
      From: <sip:test.user.mob@71.169.54.213:6512>;tag=687347f e
      To: <sip:test.user.mob@71.169.54.213:6512>;tag=as65b53 03a
      Call-ID: ZmRmYzVlZmI0NDZiZTU4N2E5MWUzYjE2ZTY5Mzk0MmE.
      CSeq: 12 REGISTER
      Server: Asterisk PBX 1.6.2.20
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
      Supported: replaces, timer
      Expires: 60
      Contact: <sip:test.user.mob@187.184.21.19:41846;transport=u dp;rinstance=c430d07101cb7f28>;expires=60
      Date: Thu, 01 Dec 2011 01:20:09 GMT
      Content-Length: 0


      <------------>
      Scheduling destruction of SIP dialog 'ZmRmYzVlZmI0NDZiZTU4N2E5MWUzYjE2ZTY5Mzk0MmE.' in 32000 ms (Method: REGISTER)

      <--- SIP read from UDP:187.184.21.19:41846 --->
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.0.16:6512;branch=z9hG4bK5e0c85d4;rport=651 2;received=71.169.54.213
      Contact: <sip:192.168.1.109:41846>
      To: <sip:test.user.mob@187.184.21.19:41846;transport=u dp;rinstance=c430d07101cb7f28>;tag=a8ea38b2
      From: "asterisk"<sip:asterisk@192.168.0.16:6512>;tag=as4 3e9ccbd
      Call-ID: 516e4a591fa261ab2a90138448ddcee3@192.168.0.16
      CSeq: 102 OPTIONS
      Accept: application/sdp
      Accept-Language: en
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
      Supported: replaces
      User-Agent: X-Lite 4 release 4.1 stamp 63214
      Content-Length: 0


      <------------->
      --- (13 headers 0 lines) ---
      Really destroying SIP dialog '516e4a591fa261ab2a90138448ddcee3@192.168.0.16' Method: OPTIONS
      Retransmitting #4 (NAT) to 187.184.21.19:41846:
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.1.109:41846;branch=z9hG4bK-d8754z-02afe691a1064cfa-1---d8754z-;received=187.184.21.19;rport=41846
      From: <sip:test.user.mob@71.169.54.213:6512>;tag=33fb229 c
      To: <sip:406@71.169.54.213:6512>;tag=as6e88e372
      Call-ID: ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI.
      CSeq: 2 INVITE
      Server: Asterisk PBX 1.6.2.20
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
      Supported: replaces, timer
      Contact: <sip:406@192.168.0.16:6512>
      Content-Type: application/sdp
      Content-Length: 284

      v=0
      o=root 1038569553 1038569553 IN IP4 192.168.0.16
      s=Asterisk PBX 1.6.2.20
      c=IN IP4 192.168.0.16
      t=0 0
      m=audio 10794 RTP/AVP 3 0 8 101
      a=rtpmap:3 GSM/8000
      a=rtpmap:0 PCMU/8000
      a=rtpmap:8 PCMA/8000
      a=rtpmap:101 telephone-event/8000
      a=fmtp:101 0-16
      a=ptime:20
      a=sendrecv

      ---
      Retransmitting #5 (NAT) to 187.184.21.19:41846:
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.1.109:41846;branch=z9hG4bK-d8754z-02afe691a1064cfa-1---d8754z-;received=187.184.21.19;rport=41846
      From: <sip:test.user.mob@71.169.54.213:6512>;tag=33fb229 c
      To: <sip:406@71.169.54.213:6512>;tag=as6e88e372
      Call-ID: ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI.
      CSeq: 2 INVITE
      Server: Asterisk PBX 1.6.2.20
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
      Supported: replaces, timer
      Contact: <sip:406@192.168.0.16:6512>
      Content-Type: application/sdp
      Content-Length: 284

      v=0
      o=root 1038569553 1038569553 IN IP4 192.168.0.16
      s=Asterisk PBX 1.6.2.20
      c=IN IP4 192.168.0.16
      t=0 0
      m=audio 10794 RTP/AVP 3 0 8 101
      a=rtpmap:3 GSM/8000
      a=rtpmap:0 PCMU/8000
      a=rtpmap:8 PCMA/8000
      a=rtpmap:101 telephone-event/8000
      a=fmtp:101 0-16
      a=ptime:20
      a=sendrecv

      ---
      Really destroying SIP dialog 'IEigEG.ek-TmsS3YyGTTsaVEz0vxrsec' Method: REGISTER
      Retransmitting #6 (NAT) to 187.184.21.19:41846:
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.1.109:41846;branch=z9hG4bK-d8754z-02afe691a1064cfa-1---d8754z-;received=187.184.21.19;rport=41846
      From: <sip:test.user.mob@71.169.54.213:6512>;tag=33fb229 c
      To: <sip:406@71.169.54.213:6512>;tag=as6e88e372
      Call-ID: ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI.
      CSeq: 2 INVITE
      Server: Asterisk PBX 1.6.2.20
      Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
      Supported: replaces, timer
      Contact: <sip:406@192.168.0.16:6512>
      Content-Type: application/sdp
      Content-Length: 284

      v=0
      o=root 1038569553 1038569553 IN IP4 192.168.0.16
      s=Asterisk PBX 1.6.2.20
      c=IN IP4 192.168.0.16
      t=0 0
      m=audio 10794 RTP/AVP 3 0 8 101
      a=rtpmap:3 GSM/8000
      a=rtpmap:0 PCMU/8000
      a=rtpmap:8 PCMA/8000
      a=rtpmap:101 telephone-event/8000
      a=fmtp:101 0-16
      a=ptime:20
      a=sendrecv

      ---
      [Nov 30 17:20:18] WARNING[12335]: chan_sip.c:4051 retrans_pkt: Maximum retries exceeded on transmission ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI. for seqno 2 (Critical Response) -- See https://wiki.asterisk.org/wiki/display/ ... nsmissions
      [Nov 30 17:20:18] WARNING[12335]: chan_sip.c:4078 retrans_pkt: Hanging up call ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI. - no reply to our critical packet (see https://wiki.asterisk.org/wiki/display/ ... nsmissions ).
      Scheduling destruction of SIP dialog '1f1866e973bc574b36d9c61c41e7e676@192.168.0.16' in 79296 ms (Method: INVITE)
      set_destination: Parsing <sip:test.user2.mob@200.79.138.41:19525;transport= UDP;ob> for address/port to send to
      set_destination: set destination to 200.79.138.41, port 19525
      Reliably Transmitting (NAT) to 200.79.138.41:19525:
      BYE sip:test.user2.mob@200.79.138.41:19525;transport=U DP;ob SIP/2.0
      Via: SIP/2.0/UDP 192.168.0.16:6512;branch=z9hG4bK10e78496;rport
      Max-Forwards: 70
      From: "test.user.mob" <sip:test.user.mob@192.168.0.16:6512>;tag=as5dcbbc bb
      To: <sip:test.user2.mob@200.79.138.41:19525;transport= UDP;ob>;tag=.Ioymo16hf.9D0fUAdIVltERfIzepInW
      Call-ID: 1f1866e973bc574b36d9c61c41e7e676@192.168.0.16
      CSeq: 103 BYE
      User-Agent: Asterisk PBX 1.6.2.20
      X-Asterisk-HangupCause: Normal Clearing
      X-Asterisk-HangupCauseCode: 16
      Content-Length: 0


      ---
      == Spawn extension (phones, 406, 1) exited non-zero on 'SIP/test.user.mob-00000059'

      <--- SIP read from UDP:200.79.138.41:19525 --->
      SIP/2.0 200 OK
      Via: SIP/2.0/UDP 192.168.0.16:6512;rport=6512;received=71.169.54.21 3;branch=z9hG4bK10e78496
      Call-ID: 1f1866e973bc574b36d9c61c41e7e676@192.168.0.16
      From: "test.user.mob" <sip:test.user.mob@192.168.0.16>;tag=as5dcbbcbb
      To: <sip:test.user2.mob@200.79.138.41;ob>;tag=.Ioymo16 hf.9D0fUAdIVltERfIzepInW
      CSeq: 103 BYE
      Content-Length: 0


      <------------->
      --- (7 headers 0 lines) ---
      Really destroying SIP dialog 'ZGJjNWEyZmE5YzFkMzE0OWQxYmZlMzMxNjlkMDYyOGI.' Method: INVITE
      Really destroying SIP dialog '1f1866e973bc574b36d9c61c41e7e676@192.168.0.16' Method: INVITE

      <--- SIP read from UDP:200.79.138.41:19525 --->


      <------------->

      <--- SIP read from UDP:187.184.21.19:41846 --->



      <------------->
      localhost*CLI>

      Comentario


      • #4
        Re: Llamada se desconecta

        Cambia el localnet para que coincida con tu red local real y prueba de nuevo. Segun veo, tienes el localnet abierto a todo.
        dCAP Christian Cabrera R.
        Para aprender a usar Asterisk, asiste a uno de mis cursos Asterisk
        Si deseas asesoría pagada, por favor contáctame

        Comentario


        • #5
          Re: Llamada se desconecta

          Ya lo he intentado inclusive dando de altas varias redes en localnet se sigues desconectando alos 10 segundos, si le quito la opcion de localnet solo tengo audio en un lado pero la llamada nos e corta.

          Comentario


          • #6
            Re: Llamada se desconecta

            LO ENCONTREEEE!!!
            EL DETALLE ERA QUE EN EL EXTERN IP NO TENIA DEFINIDO EL PUERTO!!
            Ya funciona perfectamente.

            Gracias por su tiempo y aportaciones!!

            Comentario


            • #7
              Re: Llamada se desconecta

              PLOP! jajaja, muy bien!
              dCAP Christian Cabrera R.
              Para aprender a usar Asterisk, asiste a uno de mis cursos Asterisk
              Si deseas asesoría pagada, por favor contáctame

              Comentario


              • #8
                me pasa algo parecido, configuré lo que antes era una extensión de un servidor remoto (en brazil) de la misma compañía en México, como troncal SIP, me había funcionado inidireccionalmente (solo podían hacer llamadas, no recibirlas), pero ahora aunque escucho que timbra allá no suena. Al ver el ip show peers decía unmanaged, añadí qualify y ahora dice UNREACHABLE.
                Por el mensaje supongo que no estoy alcanzando el puerto del servidor remoto, pero es raro, puedo hacer telnet a ese puerto desde mi servidor local.

                Ayudaaa.

                Comentario


                • #9
                  Recuerda que SIP (señalización) viaja por el puerto 5060 y el RTP (audio) puede elegir cualquier puerto de los definidos en rtp.conf.. probablemente puedas describir un poco mas la infraestructura y como configuraste el nateo para ver por donde se ataca
                  Hector Alvarez
                  dCAP Certified #2199
                  http://mx.linkedin.com/in/alvarezhector/

                  Comentario

                  Principales Usuarios Activos

                  Colapsar

                  No hay usuarios activos superiores.
                  Trabajando...
                  X