connecting a SIP-Trunk

Discussion in 'General' started by Dedalus, Sep 4, 2009.

  1. Dedalus

    Joined:
    Aug 19, 2009
    Messages:
    16
    Likes Received:
    0
    Thanks to the help in this forum I`ve got the Elastix-Test-Server up & running, now I want to connect an outbound SIP Trunk with nonoh.net, where I`ve an account.

    The Elastix-Server and the softphones are in the same LAN behind a NAT-Router. I want to keep it so for the time being, till I will have time to look into security measures.

    my SIP-Trunk-Settings are as follows
    Register String is myuser:pwd@sip.nonoh.net/myuser

    Outbound Route-Setting is just a dial-Pattern of "." and trunk sequence

    when dialing out, I hear immediately "all circuits are busy now, pls. try later",
    the log shows:
    when replacing sip.nonoh.net in peer settings with the pinged ip, it`s basiclly the same announcement, just it takes about 30 sec for the message to come...
    and the log is now:
    when replacing the sip.nonoh.net with the pinged ip also in the registration string,
    the log grows rapidly with "No match Their Call ID", followed from time to time by other messages

    Am I Missing somewhere a STUN-Server setting? Can somebody enlighten me please?

    Many thanks in advance :)
     
  2. danardf

    Joined:
    Dec 3, 2007
    Messages:
    8,069
    Likes Received:
    12
    I try to help you. :)

    First time, you could put nat=yes into your config trunk, and put:
    externip=your public ip or
    externhost=your_host.domain
    localnet=192.168.1.0/255.255.255.0
    for example

    and this, into sip_nat.conf

    Add also your prefered codec itno your trunk (for example) :
    disallow=all
    allow=ulaw
    allow=G729


    If you don't do it, you shouldn't have communication, because the trunk don't know what codec used.

    Add also into your trunk a:
    qualify=yes

    Reload asterisk server (CLI> reload or CLI> restart now)

    If you try to ping sip.nonoh.net and you haven't result, it's because you don't have the config dns parameters from device Eth!

    Go to web gui - system - network and put your dns server into your config.

    Next, you must redirect 2 ports from (SIP & RTP) to your IP Elastix server. So 5060 and from 10000 to 20000 in UDP.


    Try this.
     
  3. Dedalus

    Joined:
    Aug 19, 2009
    Messages:
    16
    Likes Received:
    0
    danardf, thx. for your suggestions and patience with me newbie :)

    My Peer Details look now like this:
    sip_nat.conf looks like this:
    Ports forwarded and verified. When trying to connect, I immidiately get:
    ...hope that these 3 lines out of 160 tell you more than me... any advice is welcomed :)
     
  4. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    please post the output of (from bash):

    rasterisk -x 'sip show peers'
    and
    rasterisk -x 'sip show registry'
    and
    ping -c 3 sip.nonoh.net

    you wrote:
    allow=ulaw&G729

    unless you have g729 devices or licenses don't use it
    your provider is non explicit as to which variation of g711 it accepts, it seems euro and you are trying to call Austria I suggest:

    allow=alaw&ulaw

    instead


    further
    nat=yes

    doesn't belong in the trunk setting, it is more appropriate in the SIP settings, you need to check with the VSP as to whether you need to register with them to call out (usually not, it's normally needed for inbound only)) and if so what would you need in the register string, as apparently yours is failing.

    STUN is a red herring here, don't worry about it.
     
  5. Dedalus

    Joined:
    Aug 19, 2009
    Messages:
    16
    Likes Received:
    0
    Hi dicko :)

    you brought me on the right track... the default gateway was for some reason not set :blush: so outgoing trunk is working, the incoming (sipgate) seems not to register:
    any idea what could be the reason? for sure again something stupid, but I can`t find it... in the log there are a lot of this:
    don`t understand the from / to lines. is it ok, if they are the same (sip:myuser#@sipgate.de)?
     
  6. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    I believe I do have some answers for you,

    your SIP registration attempt to sipgate.de is being rejected, . . . SIP/2.0 401 Unauthorized . . . you need to check your registration syntax, and double check with them as to it's veracity.

    and

    that to/from thing is ok, SIP (Session Initiation Protocol) is all about getting a point to point connection, then verifying validity of sender/sendee then negotiating a mutually acceptable media path (upd/tcp/rtp/tty/braille etc. and any codecs inline) for the audio/video/multicast/unicast (ok I'll shut up just call it audio for now), the via line is usually far more diagnostic as to failures. it's all about navigating through firewalls/pnat , the fact that you got the rejection means largely that the nat-ting is working, you just didn't send them what they find acceptable.


    (glad you're getting there)
    from bash:
    rasterisk -x 'sip debug ip sipgate.de'&&tail -f /var/log/asterisk/full; rasterisk -x 'sip set debug off'

    (control C when the mesmerization wears off)

    for a fuller trace of your transactions with that provider.



    dicko
     
  7. danardf

    Joined:
    Dec 3, 2007
    Messages:
    8,069
    Likes Received:
    12
    Oups sorry, Yes... I forgot. :blush:

    Thanks Dicko to fix this point. (Hi Dicko ;) )
     
  8. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    Hey Franck, you are up early again!

    I filled in for you in your absence, he's all yours.

    Dick
     
  9. danardf

    Joined:
    Dec 3, 2007
    Messages:
    8,069
    Likes Received:
    12
    Yes ... I'm awake at 5 AM.

    If you want, you can continue, because I go to a picknik today, and tonight, It's the birthday at my wife (39). SO.. tomorrow, hipsss. :laugh:
    You see? ;)
     
  10. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    I thought the Academie Francaise made "le pic-nic a weekend" not cool , n'est pas?

    from wikipedia

    . . . Due to the leading role of English among the other languages of the world, the Académie's tends to focus on lessening the influx of English words into French by choosing and recommending the use of French equivalents. One recent example is the Académie's recommendation of the use of the word "courriel" instead of the English "e-mail".
    . . . . (lucky that you are not really French :) )

    Enjoy your day and wish your Wife a Joyeux anniversaire from me.
     
  11. danardf

    Joined:
    Dec 3, 2007
    Messages:
    8,069
    Likes Received:
    12
    he.... yes picnic - pic-nic. Of course. (I back to my bed)

    Thanks Dicko. :laugh:
     
  12. Dedalus

    Joined:
    Aug 19, 2009
    Messages:
    16
    Likes Received:
    0
    Hi Guys,

    thanks for you inputs - have double and tripple checked the settings. The outgoing sip-trunk was working (thx dicko for your hint not to register it), the incoming not registering, even a softphone with exactly the same credentials managed to register...

    Thanks to the hint that it`s about credentials, i tried two other sip provider, sipgate.at being one of them (and the setting despite the credentials the same as sipgate.de), both managed to register.

    Even i`m not fully satisfied not knowing what went wrong, i have now anyway two incoming and one outgoing trunks. Need to learn how to use both incoming sip-trunks at the same time, having no did from provider. So for the beginning something to test with - and fortunately i`ve a bit time till it should go into production :)

    Next steps will be using both incoming trunks in parallel, then connecting Nokia phones.

    have a fine weekend, and Franck hope the weather was for your pique-nique :) better than here in Vienna br., Leon
     
  13. zymotik

    Joined:
    Jan 10, 2013
    Messages:
    1
    Likes Received:
    0

Share This Page