# Problem access my server from outside connection

**URL:** <https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221>\
**Category:** Asterisk Support\
**Created:** [December 19, 2007, 9:55am UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221 "2007-12-19T09:55:07Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![look2](https://avatars.discourse-cdn.com/v4/letter/l/85f322/32.png) [@look2](https://community.asterisk.org/u/look2)\
**Post date:** [December 19, 2007, 9:55am UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/1 "2007-12-19T09:55:07Z")

</div>

Hi!

I have just installed asterisknow and got it working internal on my LAN at home. I have tested it with a soft phone on the pc and my nokia n95 cell phone and I can make calls between them.

When I tried with my cell phone from an external internet connection the phone indicates that it’s registered with the asterisk server, but when I’m trying to make a call to a local extension on the server it won’t work. I hear nothing in the phone and after a while the call gets disconnected.

The server is behind a NAT so I have tried to open port 5060 and forward it to the internal ip of the asterisk server, but the only thing that is working is to register the phone. Do I need to open and forward some more ports? Or is there something else I have missed?

//Oscar

---

<div class="post-metadata">

**Author:** ![AsteriskDude](https://avatars.discourse-cdn.com/v4/letter/a/a183cd/32.png) [@AsteriskDude](https://community.asterisk.org/u/AsteriskDude)\
**Post date:** [December 19, 2007, 6:43pm UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/2 "2007-12-19T18:43:39Z")

</div>

have you forwarded RTP packets to your \* box??? RTP is your actual voice media…Hope this helps.

RTP ports are defined in /etc/asterisk/rtp.conf

default is 10000-20000.

no need to open all 10,000 ports. 20 or 25 ports is more than enough for a small environment.

---

<div class="post-metadata">

**Author:** ![look2](https://avatars.discourse-cdn.com/v4/letter/l/85f322/32.png) [@look2](https://community.asterisk.org/u/look2)\
**Post date:** [December 20, 2007, 8:11pm UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/3 "2007-12-20T20:11:31Z")

</div>

I got a little bit further.  
If a client (softphone) inside the nat connects to \*box and a client (softphone) connects to the \*box. They can communicate and make calls to each outer.

The outside softphone can here the inside softphone but not the outher way arround. What can causing this problem ?

---

<div class="post-metadata">

**Author:** ![look2](https://avatars.discourse-cdn.com/v4/letter/l/85f322/32.png) [@look2](https://community.asterisk.org/u/look2)\
**Post date:** [December 20, 2007, 8:45pm UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/4 "2007-12-20T20:45:48Z")

</div>

woohooo  
i got it working.  
Had to add my own externa ip adress in the sip.conf file and after that it’s working

---

<div class="post-metadata">

**Author:** ![XiN](https://avatars.discourse-cdn.com/v4/letter/x/bbce88/32.png) [@XiN](https://community.asterisk.org/u/XiN)\
**Post date:** [December 21, 2007, 4:15pm UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/5 "2007-12-21T16:15:14Z")

</div>

Uh! Could you tell me where did you add it?

---

<div class="post-metadata">

**Author:** ![look2](https://avatars.discourse-cdn.com/v4/letter/l/85f322/32.png) [@look2](https://community.asterisk.org/u/look2)\
**Post date:** [December 22, 2007, 10:19pm UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/6 "2007-12-22T22:19:22Z")

</div>

Juste added in the file so it now looks like this

context=default  
allowoverlap=no  
bindport=5060  
bindaddr=0.0.0.0  
srvlookup=yes  
[externip=xxx.xxx.xxx.xxx](http://externip=xxx.xxx.xxx.xxx)  
nat=yes  
localnet=yyy.yyy.yyy.yyy/255.255.255.0

Where xxx is my external ip adress and yyy is the internat adress

---

<div class="post-metadata">

**Author:** ![XiN](https://avatars.discourse-cdn.com/v4/letter/x/bbce88/32.png) [@XiN](https://community.asterisk.org/u/XiN)\
**Post date:** [December 24, 2007, 9:42am UTC](https://community.asterisk.org/t/problem-access-my-server-from-outside-connection/18221/7 "2007-12-24T09:42:41Z")

</div>

Ah ok…i see thank you…
