I currently have my main asterisk server running on a public IP. I have several local phones talking to and from it.
Just recently I have added some remote phones. Because the remote phones were in a location that had a NAT, these phones needed a local asterisk server to talk to. I implemented 2nd asterisk server on that local network and the phones are talking to that server and registering the private IP’s no problem. I have setup iax so that these remote phones can call to and through my main * server on the public IP.
Up until this point everything is working fine. When I do a ‘iax2 show peers’ on my remote server behind the NAT it shows that I am connected to my main server. However, on the main server when I so a ‘iax2 show peers’ it says that my remote server is UNREACHABLE. Therefore I can only make outgoing calls on my remote network and cannot receive any from the main server. Is there something else I can do to make this server receive incoming calls as well?
This is my main server iax.conf:
555=remote server behind NAT
playpen=main server on public IP
[general] bindport=4569 bindaddr=0.0.0.0 disallow=all allow=ulaw allow=alaw allow=gsm mailboxdetail=yes  type=friend username=playpen secret=password auth=plaintext host=126.96.36.199 context=sip peercontext=sip qualify=yes trunk=yes
This is the remote server: