[Home]

Summary:ASTERISK-22865: externhost is not work
Reporter:wangpeng (voipwangpeng)Labels:
Date Opened:2013-11-19 03:48:44.000-0600Date Closed:2013-11-19 20:54:34.000-0600
Priority:MajorRegression?
Status:Closed/CompleteComponents:
Versions:11.5.0 Frequency of
Occurrence
Related
Issues:
Environment:ubuntu 12.0.4 Attachments:( 0) 8015-8014.pkt
Description:
machine ip is 192.168.0.198

my sip.conf is 
localnet=192.168.0.0/255.255.255.0
externhost=xxx.f3322.org

[8014]
type=friend
username=8010
secret=8010
host=dynamic
context=from-internal
qualify=yes
nat=yes
directmedia=no

[8015]
type=friend
username=8010
secret=8010
host=dynamic
context=from-internal
qualify=yes
nat=yes
directmedia=no


8015 and asterisk are behind nat(private net),8014 register to asterisk with 8014@xxx.f3322.org through 3g net,and i have port map 5060 and 10000~11000 of 192.168.0.198 on router,and router dns is ok,because i ping xxx.f3322.org is ok ,and 8014 is register see on asterisk cmd.


now 8015 call 8014,but media ip in sdp what asterisk back to 8015 and 8014 is 192.168.0.198,not public ip,so i think externhost is not work, so pls resolve it.

chan_sip.c/add_sdp->ast_sockaddr_stringify_addr_remote->ast_sockaddr_stringify_fmt




Comments:By: wangpeng (voipwangpeng) 2013-11-19 03:51:15.237-0600

package

By: wangpeng (voipwangpeng) 2013-11-19 20:27:17.868-0600

log when asterisk start

[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:138 ast_sockaddr_split_hostport: Splitting '192.168.0.0' into...
[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:192 ast_sockaddr_split_hostport: ...host '192.168.0.0' and port ''.
[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:138 ast_sockaddr_split_hostport: Splitting '255.255.255.0' into...
[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:192 ast_sockaddr_split_hostport: ...host '255.255.255.0' and port ''.
[Nov 20 10:20:09] DEBUG[12869]: acl.c:720 ast_append_ha: 192.168.0.0:0/255.255.255.0:0 sense 0 appended to ACL
[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:138 ast_sockaddr_split_hostport: Splitting 'eullansh.f3322.org' into...
[Nov 20 10:20:09] DEBUG[12869]: netsock2.c:192 ast_sockaddr_split_hostport: ...host 'eullansh.f3322.org' and port ''.
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
ubuntu*CLI>
   -- Message check requested for mailbox 4003/folder INBOX but voicemail not loaded.
   -- Message check requested for mailbox 4004/folder INBOX but voicemail not loaded.
   -- Message check requested for mailbox 4004/folder INBOX but voicemail not loaded.
   -- Message check requested for mailbox 4004/folder INBOX but voicemail not loaded.
[Nov 20 10:20:29] ERROR[12869]: netsock2.c:269 ast_sockaddr_resolve: getaddrinfo("eullansh.f3322.org", "(null)", ...): No address associated with hostname
[Nov 20 10:20:29] WARNING[12869]: chan_sip.c:31857 reload_config: Invalid address for externhost keyword: eullansh.f3322.org
[Nov 20 10:20:29] DEBUG[12869]: netsock2.c:138 ast_sockaddr_split_hostport: Splitting 'ubuntu' into...
[Nov 20 10:20:29] DEBUG[12869]: netsock2.c:192 ast_sockaddr_split_hostport: ...host 'ubuntu' and port ''.

By: wangpeng (voipwangpeng) 2013-11-19 20:54:34.057-0600

dns server is not response
after change dns server, it is ok