Closed tsawyer closed 1 month ago
$0.02 : using the SRV record to get the hostname and IAX port makes sense, and will likely help with IPv6 support, but it does mean that each lookup will be 2+ DNS queries (one for the SRV record, one for the A record, etc). Right now, we're only issuing a single TXT query and we get back all the info we need.
At the time that the DNS code was written, the remote base lookup was broken. The only option forward was to use the TXT records. You are correct, it will take two queries to achieve the same results. It is unfortunate that the TXT records are not working.
I will get some changes together for testing. It is unfortunate that the TXT records are not working.
It is unfortunate that the TXT records are not working.
I thought @ajpaul25 just fixed the TXT record issue and that this issue was more to get the node lookup code to follow the original (SRV + A/AAAA) plan.
I'm not sure he fixed the TXT records or something else, but according to him they are for debugging only.
@KB4MDD are you looking at https://www.asterisk.org/res_resolver_unbound/
I had already written the SRV lookup code, but it would not work due to a problem with remote bases. Because of the problem, I switched to the TXT records. The SRV lookup code has been added. I left the original TXT lookup code and disabled it -- just in case it can be used in the future.
The SRV lookup method requires two DNS requests. The TXT record only required one DNS request.
Change ASL to use core Asterisk DNS services to resolve ASL node numbers, remote base node numbers and future ASL services.
My limited understanding of how this done is to query the SVR record first to find the A record. Apparently TXT records are for debugging and should not be used for ASL address resolution.
An example query of a remote base node is shown below. Also shown is a link to the ASL DNS specification and a blog post about PJSIP DNS.
https://wiki.allstarlink.org/wiki/DNS_Servers https://www.asterisk.org/pjsip-dns-support/