[asterisk-bugs] [Asterisk 0013900]: [feature request] Asterisk does not respect DNS TTL in iax.conf

Asterisk Bug Tracker noreply at bugs.digium.com
Wed Dec 17 16:29:55 CST 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=13900 
====================================================================== 
Reported By:                ffadaie
Assigned To:                mvanbaak
====================================================================== 
Project:                    Asterisk
Issue ID:                   13900
Category:                   Channels/chan_iax2
Reproducibility:            always
Severity:                   feature
Priority:                   normal
Status:                     assigned
Asterisk Version:           1.4.22 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             2008-11-13 23:07 CST
Last Modified:              2008-12-17 16:29 CST
====================================================================== 
Summary:                    [feature request] Asterisk does not respect DNS TTL
in iax.conf
Description: 
This is probably not specific to IAX but I just tried it for IAX so I am
not sure about the other channels.
The problem is :
when you Dial and IAX channel either by direct dialing
Dial(IAX2/@some_host_name/extension) or by referring to a section in
iax.conf Dial(IAX2/@[section]/extension) and the host names are not IP
addresses but DNS names, Asterisk does not care if the resolved address
changes.
In other words, lets say you have a dynamic DNS that translates to IP_1
and you use this in your configuration in Asterisk. If this IP changes
Asterisk would not respect it and keeps using the old IP until you reload.
It seems that Asterisk resolves the DNS and stores the IP in the memory
(as oppose to having the DNS entry and resolving it each time)
====================================================================== 

---------------------------------------------------------------------- 
 (0096594) ffadaie (reporter) - 2008-12-17 16:29
 http://bugs.digium.com/view.php?id=13900#c96594 
---------------------------------------------------------------------- 
It sounds like a good idea. So, what you are going to modify dnsmanager to
become a tiny dns server (BIND if you will as I am not that big of a MS
fan).
The reason that I am saying it should somehow be a DNS server is that some
parts of DNS protocol should be implemented. For example, if TTL changes,
then dnsmanager should know about it. In other words, it cannot calculate
the lowest TTL returned by the lookups at the beginning and uses that for
ever. That would cause similar problems with what we have right now.
The following steps should be taken (in my opinion):
1- Resolve the names
2- Calculate the lowest TTL (lets call that LTTL)
3- wait LTTL
4- goto 1
I can't think of any other issues right now that could potentially be an
RFC breaker.
I may have proposed the same idea as you did because of the lack of
details in your comment. I apologize if that's the case.

Cheers, 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2008-12-17 16:29 ffadaie        Note Added: 0096594                          
======================================================================




More information about the asterisk-bugs mailing list