[Home]

Summary:ASTERISK-14719: dnsmgr refreshes hostname, but changes SIP port to 0
Reporter:Bob M (manchicken)Labels:
Date Opened:2010-06-10 10:48:17Date Closed:2010-06-17 09:26:25
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/Configuration
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) debug_17496.txt
Description:Have a SIP 'friend' for outbound calls through Vitelity, set with host=outbound.vitelity.net.  DNS manager is refreshing the IP for 'outbound.vitelity.net' but changing the SIP port number to 0 for the peer when it does - see console output below, showing the list of peers with proper port numbers, a manual 'dnsmgr refresh', and it subsequently setting the port to 0.

****** ADDITIONAL INFORMATION ******

metallus*CLI> sip show peers
Name/username              Host            Dyn Nat ACL Port     Status
Bob-Softphone/Bob-Softpho  (Unspecified)    D   N      5060     UNKNOWN
Home/Home                  192.168.1.9      D   N      5060     OK (14 ms)
Home-PSTN/Home-PSTN        192.168.1.9      D          5061     OK (5 ms)
vitelity-in                64.2.142.108                5060     Unmonitored
vitelity-out               64.2.142.29                 5060     Unmonitored
5 sip peers [Monitored: 2 online, 1 offline Unmonitored: 2 online, 0 offline]

metallus*CLI> dnsmgr refresh
   -- Refreshing DNS lookups.
   -- refreshing 'inbound8.vitelity.net'
   -- refreshing 'spark.idolum.com'
   -- refreshing 'outbound.vitelity.net'
[Jun 10 09:35:00] NOTICE[13766]: dnsmgr.c:172 dnsmgr_refresh: dnssrv: host 'outbound.vitelity.net' changed from 64.2.142.29:0 to 64.2.142.18:0
   -- refreshing 'inbound8.vitelity.net'
   -- refreshing 'spark.idolum.com'

metallus*CLI> sip show peers
Name/username              Host            Dyn Nat ACL Port     Status
Bob-Softphone/Bob-Softpho  (Unspecified)    D   N      5060     UNKNOWN
Home/Home                  192.168.1.9      D   N      5060     OK (12 ms)
Home-PSTN/Home-PSTN        192.168.1.9      D          5061     OK (5 ms)
vitelity-in                64.2.142.108                5060     Unmonitored
vitelity-out               64.2.142.18                 0        Unmonitored
5 sip peers [Monitored: 2 online, 1 offline Unmonitored: 1 online, 1 offline]
Comments:By: Bob M (manchicken) 2010-06-10 12:08:18

FYI, I just built 1.6.2.8 and experience the same problem.

By: Paul Belanger (pabelanger) 2010-06-10 13:15:24

We require a complete debug log to help triage the issue.

This document will provide instructions on how to collect debugging logs from an Asterisk machine for the purpose of helping bug marshals troubleshoot an issue:

http://svn.digium.com/svn/asterisk/trunk/doc/HOWTO_collect_debug_information.txt

By: Bob M (manchicken) 2010-06-13 15:22:23

Attached a debug dump, it's a little large with extra junk as it's captured from startup since dnsmgr isn't a module I can reload.

By: Paul Belanger (pabelanger) 2010-06-16 15:52:37

ManChicken: Can you upgrade to the latest 1.6.2 branch?  I suspect this was just fixed.

By: Bob M (manchicken) 2010-06-17 02:29:30

I just fetched SVN-trunk-r271089 and built it,  and indeed this is fixed!

By: Digium Subversion (svnbot) 2010-06-17 09:25:12

Repository: asterisk
Revision: 270974

U   trunk/main/acl.c
U   trunk/main/dnsmgr.c

------------------------------------------------------------------------
r270974 | mnicholson | 2010-06-16 15:34:31 -0500 (Wed, 16 Jun 2010) | 11 lines

Set sin_family to AF_INET when doing lookups, also reset sin_port the first time the ip address changes.

(closes issue ASTERISK-14719)
Reported by: ManChicken

(closes issue ASTERISK-14767)
Reported by: DennisD
Patches:
     dnsmgr_15827.patch uploaded by chappell (license 8)
Tested by: DennisD, gentlec, damage, wimpy

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=270974

By: Digium Subversion (svnbot) 2010-06-17 09:26:25

Repository: asterisk
Revision: 270975

_U  branches/1.6.2/
U   branches/1.6.2/main/acl.c
U   branches/1.6.2/main/dnsmgr.c

------------------------------------------------------------------------
r270975 | mnicholson | 2010-06-16 15:41:40 -0500 (Wed, 16 Jun 2010) | 18 lines

Merged revisions 270974 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
 r270974 | mnicholson | 2010-06-16 15:34:31 -0500 (Wed, 16 Jun 2010) | 8 lines
 
 Set sin_family to AF_INET when doing lookups, also reset sin_port the first time the ip address changes.

 (closes issue ASTERISK-14719)
 Reported by: ManChicken
 
 (closes issue ASTERISK-14767)
 Reported by: DennisD
 Patches:
       dnsmgr_15827.patch uploaded by chappell (license 8)
 Tested by: DennisD, gentlec, damage, wimpy
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=270975