[SR-Users] $HN(d) null when DNS cache is enabled
Julien Klingenmeyer
julien.klingenmeyer at gmail.com
Wed Feb 13 14:32:39 CET 2019
Hello,
I have a small question regarding the internal DNS resolver.
Here is my current Kamailio DNS configuration:
dns_try_naptr=on
use_dns_failover=yes
use_dns_cache=yes
I need the $HN variable inside my script and it appeared while testing that
$HN(d) was null (and consequently $HN(f) was only containing the hostname
part of the FQDN).
I know /etc/hosts file is bypassed when the DNS cache is activated, so I
thought Kamailio was using the domain parameter set in the /etc/resolv.conf
file in such cases in order to get the domain. But it was not.
I figured out Kamailio correctly retrieves the domain name as long as it is
explicitly part of the /etc/hostname file.
Is my understanding correct or am I wrong somewhere? What if /etc/hostname
does not contain the domain name but hostname only?
Thanks!
Cheers
Julien
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20190213/763ad5bd/attachment.html>
More information about the sr-users
mailing list