Incoming call problem

VitalPBX Community Support General Discussion Incoming call problem

  • Post
    slemoal
    Participant
    Hello, I have a problem routing my incoming calls with a SEWAN sip operator.

    My outgoing calls it’s OK, but the DID does not match or incomming calls.

    After analyzing the traces, it seems that the DID is in the To field.
    To: <sip: 0351XXXX08@yyyyy.sewan.eu>; tag = as5f65fc75

    Can you help me? this is my first VitalPBX installation, even if I am not new to asterisk distro.

    Attached is the full trace of an incoming call and my sip trunk configuration

    PS: Sorry for my English 🙂

    Attachments:
    You must be logged in to view attached files.
    0
Viewing 12 replies - 1 through 12 (of 12 total)
  • Replies
    Rodrigo Cuadra
    Keymaster
    US
    Up
    0
    Down
    You need to add the DID number that you are dialed from outside the PBX.
    Go to: PBX / External / Inbound Routes

    Description: Whatever you want

    DID Pattern: The exact DID number as published.

    Inbound Destrination: Select where to ring when dialing that DID from outside the PBX.

    0
    slemoal
    Participant
    Up
    0
    Down
    Hello and thank you for your help.
    As you will see in the screenshot below this is already the case.

    The only rule for making a successful call is if I put “_.”

    Attachments:
    You must be logged in to view attached files.
    0
    Rodrigo Cuadra
    Keymaster
    US
    Up
    0
    Down
    Are you sure you are receiving the DID exactly as you set it: 0351 ….?

    To verify this I recommend that you go to the asterisk CLI in the linux console:
    asterisk -rvvvvvvvvvvvvvvvvvvvvvvv
    and you make a call and there you can see the number that you are actually receiving as DID.

    0
    slemoal
    Participant
    Up
    0
    Down
    if in my inbound route I put “_X.”

    then it doesn’t work. I have the message:

    voice*CLI>
    == Using SIP RTP TOS bits 184
    == Using SIP RTP CoS mark 5
    voice*CLI>

     

    But if I put: “_.”
    So there I get the call.

    Which leads me to think that my first character is not a number…

     

     

     

     

    0
    Rodrigo Cuadra
    Keymaster
    US
    Up
    0
    Down
    This reply has been marked as private.
    0
    slemoal
    Participant
    Up
    0
    Down
    I found the “bug”
    /etc/asterisk/vitalpbx/sip__50-1-trunks.conf
    [trunkxxxxx](p13)
    context=trk-1-in
    description=Trunk_sip_Sewan
    dtmfmode=rfc2833
    allow=!all,alaw,ulaw,g729
    nat=no
    host=37.97.65.78
    port=5070
    secret=ppppp
    insecure=port,invite
    defaultuser=trunkxxxxx
    remotesecret=ppppp
    fromdomain=yyyy.sewan.eu
    qualify=yes
    type=peer

    /etc/asterisk/vitalpbx/extensions__50-1-dialplan.conf

    My trunk has the context: [trk-1-in]

    [trk-1-in]
    exten => _[+*#0-9A-Za-z].,1,NoOp(Incoming call through: Trunk_sip_Sewan)
    same => n,Set(__TRUNK_ID=1)
    same => n,Set(CDR(trunk)=1)
    same => n,Set(__DID_NUMBER=${EXTEN})
    same => n,Set(CDR(did)=${EXTEN})
    same => n,Set(DID=${EXTEN})
    same => n,Set(DID=${IF($["${CHANNEL(channeltype)}"="SIP"]?${CUT(CUT(SIP_HEADER(To),@,1),:,2)}:${CUT(CUT(PJSIP_HEADER(read,To),@,1),:,2)})})
    same => n,Goto(default-trunk,${DID},1)

    if I change the first line to:
    exten => _.,1,NoOp(Incoming call through: Trunk_sip_Sewan)
    and that I reload the dialplan in CLI it works.
    The problem is that as soon as I modify in GUI it regenerates the plan of num with the problem …

    • This reply was modified 2 weeks, 6 days ago by slemoal.
    0
    Rodrigo Cuadra
    Keymaster
    US
    Up
    -3
    Down
    This reply has been marked as private.
    0
    slemoal
    Participant
    Up
    0
    Down
    After several tries with Rodrigo (again thank you for your time) the problem comes from the rule: “_ [+ * # 0-9A-Za-z].” which does not match needing at least 2 characters.
    Excluding after analysis of the traces we only receive the “s” the DID being subsequently retrieved in the TO field

    The workaround is as follows:

    nano /etc/asterisk/vitalpbx/extensions__50-1-dialplan_custom.conf

    add dialplan

    [trk-1-in-custom]
    exten => _.,1,NoOp(Incoming call through: Trunk_sip_Sewan)
    same => n,Set(__TRUNK_ID=1)
    same => n,Set(CDR(trunk)=1)
    same => n,Set(__DID_NUMBER=${EXTEN})
    same => n,Set(CDR(did)=${EXTEN})
    same => n,Set(DID=${EXTEN})
    same => n,Set(DID=${IF($["${CHANNEL(channeltype)}"="SIP"]?${CUT(CUT(SIP_HEADER(To),@,1),:,2)}:${CUT(CUT(PJSIP_HEADE$
    same => n,Goto(default-trunk,${DID},1)

    put the rights

    chmod +x /etc/asterisk/vitalpbx/extensions__50-1-dialplan_custom.conf

    In the advanced tab of the trunk, Custom Settings

    type=peers
    parameter= context 
    value= trk-1-in-custom

    This procedure must be valid for all SIP operators which indicate the DID in the TO field (like OVH)

    en français:

    Apres plusieurs essai avec Rodrigo (encore merci pour votre temps) le probleme vient bien de la règle: “_[+*#0-9A-Za-z].” qui ne matche pas ayant besoin de 2 caractères minimum.
    Hors après analyse des trace nous ne recevons que le “s” le DID Ă©tant rĂ©cupĂ©rĂ© par la suite dans le champs TO

    La solution de contournement est la suivante:

    créer un fichier custom

    nano /etc/asterisk/vitalpbx/extensions__50-1-dialplan_custom.conf

    Ajouter le dialplan ci-dessous

    [trk-1-in-custom]
    exten => _.,1,NoOp(Incoming call through: Trunk_sip_Sewan)
    same => n,Set(__TRUNK_ID=1)
    same => n,Set(CDR(trunk)=1)
    same => n,Set(__DID_NUMBER=${EXTEN})
    same => n,Set(CDR(did)=${EXTEN})
    same => n,Set(DID=${EXTEN})
    same => n,Set(DID=${IF($["${CHANNEL(channeltype)}"="SIP"]?${CUT(CUT(SIP_HEADER(To),@,1),:,2)}:${CUT(CUT(PJSIP_HEADE$
    same => n,Goto(default-trunk,${DID},1)

    Mettre les droits d’exĂ©cution

    chmod +x /etc/asterisk/vitalpbx/extensions__50-1-dialplan_custom.conf

     

    Dans l’onglet avancĂ© du trunk, Custom Settings

    type=peers
    parameter= context 
    value= trk-1-in-custom

    Cette procédure doit être valable pour tout les opérateurs SIP qui indique le DID dans le champs TO (comme OVH)

    0
    slemoal
    Participant
    Up
    0
    Down
    Hello, you will find attached the configuration procedure with the sewan operator, and the definitive workaround for the did in the to field

    Tutorial

    0
    Up
    0
    Down
    In the registry string, you can do something like this:

    trunkyyyyy@test.sewan.eu:PASSzzzzz@37.97.65.78:5070/PILOT_NUMBER
    
    e.g:

    trunkyyyyy@test.sewan.eu:PASSzzzzz@37.97.65.78:5070/12345667

    The above configuration means that any call coming from that trunk will be sent to the DID “12345667

    0
    CD
    Participant
    Up
    0
    Down
    Hello,

    I recently installed VitalPBX.

    I’m facing the below problem would appreciate your help.

    I’ve created 2 extensions (Extension 10 & Extension 12)

    extension 10 is configured on an I-Phone and registered correctly

    extension 12 is configured on a laptop with windows 10

    I am able to call successfully from extension 10 to extension 12

    when I try to call from extension 12 to extension 10 it is unsuccessful and showing the following error “Remote Party Declined the Call”

    thank you in advance.

    0
    CD
    Participant
    Up
    0
    Down
    Now I am also not able to call from 1 Vitalpbx communicator to another Vitalpbx communicator. It rings, but when I answer it state that the person you are calling is unavailable
    0
Viewing 12 replies - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.