# Sip trunk host=dynamic

**URL:** <https://community.asterisk.org/t/sip-trunk-host-dynamic/45919>\
**Category:** Asterisk Support\
**Created:** [April 17, 2014, 1:46pm UTC](https://community.asterisk.org/t/sip-trunk-host-dynamic/45919 "2014-04-17T13:46:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mothertrucker](https://avatars.discourse-cdn.com/v4/letter/m/51bf81/32.png) [@mothertrucker](https://community.asterisk.org/u/mothertrucker)\
**Post date:** [April 17, 2014, 1:46pm UTC](https://community.asterisk.org/t/sip-trunk-host-dynamic/45919/1 "2014-04-17T13:46:53Z")

</div>

Hi Guys

i´ve a problem with my system, i hope you can help me.  
I try to connect 2 Asterisk by a sip trunk. If i look at sip show peers and sip show registry everthing is ok.  
This is my config:

Server2:  
[xxx]  
username=xxx  
type=friend  
secret=kjf72356kfh5  
host="ip"  
disallow=all  
allow=alaw  
allow=ulaw  
dtmfmode=rfc2833  
context=default

register=xxx:kjf72356kfh5@ip/xxx

server2:  
[xxx]  
username=xxx  
type=friend  
secret=kjf72356kfh5  
host=dynamic  
disallow=all  
allow=alaw  
allow=ulaw  
dtmfmode=rfc2833  
context=from-test-outbound

Calls from server1 to server2 work, but calls from sip1 to com1 doesn´t work.  
A console dial from sserver2 tells me this:

– Executing [1100@from-pstn:8] Dial(“Console/default”, “SIP/123456789/1100”) in new stack  
== Everyone is busy/congested at this time (1:0/0/1)  
– Executing [1100@from-pstn:9] NoOp(“Console/default”, “es geht weiter”) in new stack  
– Executing [1100@from-pstn:10] Hangup(“Console/default”, “”) in new stack

Over a tcpdump i can see that server2 doesn´t send anything to com1.  
If i change the host=dynamic from server2 to the host=“ip” it works.  
But the host need to be dynamic

Hope you can help me.

Thank you for your help.

MotherTrucker

---

<div class="post-metadata">

**Author:** ![mothertrucker](https://avatars.discourse-cdn.com/v4/letter/m/51bf81/32.png) [@mothertrucker](https://community.asterisk.org/u/mothertrucker)\
**Post date:** [May 6, 2014, 6:16am UTC](https://community.asterisk.org/t/sip-trunk-host-dynamic/45919/2 "2014-05-06T06:16:24Z")

</div>

Has nobody any Idea or something else?

---

<div class="post-metadata">

**Author:** ![david55](https://avatars.discourse-cdn.com/v4/letter/d/e19adc/32.png) [@david55](https://community.asterisk.org/u/david55)\
**Post date:** [May 6, 2014, 8:39am UTC](https://community.asterisk.org/t/sip-trunk-host-dynamic/45919/3 "2014-05-06T08:39:18Z")

</div>

You haven’t provided enough information. You’ve even not recorded the message reporting the peer as unavailable.

Most likely, the registration failed.

Normally, in this sort of case, one bypasses the problem by making both sides have static addresses.

Note, you shouldn’t use the same name for both peers, although I’m not convinced that will actually cause the problem.

Also, you should use type=peer, although, again, that is probably not the problem here.
