Koozali.org: home of the SME Server

Is there NO answer to this DNS issue?

E_Chudra

Is there NO answer to this DNS issue?
« on: January 23, 2004, 07:22:25 PM »
Since upgrading to v6 all dns requests from the sme server are returning the generic host records and not the records I have entered into the hostname panel.  The entries are still in the host panel but when the server is polled it returns the generic host A record ie. pc-0005.domain.com.  I am ready to copy the host file to every machine.

E

tape

Re: Is there NO answer to this DNS issue?
« Reply #1 on: January 25, 2004, 05:33:49 PM »
Quote from: "E_Chudra"
Since upgrading to v6 all dns requests from the sme server are returning the generic host records and not the records I have entered into the hostname panel.  The entries are still in the host panel but when the server is polled it returns the generic host A record ie. pc-0005.domain.com.  I am ready to copy the host file to every machine.

E


http://forums.contribs.org/index.php?topic=18917.msg74760#msg74760

E_Chudra

Is there NO answer to this DNS issue?
« Reply #2 on: January 26, 2004, 06:49:36 PM »
I forgot to mention I am NOT using DHCP for these addresses they are assigned in the HOSTNAME panel.

Graeme Fleming

DNS Issue
« Reply #3 on: January 27, 2004, 08:43:08 PM »
Version 6 uses TinyDNS not Bind and my guess is that they behave slightly differently (or SME handles them differently) - you may need to add the MAC address for the client NIC to the matching hostname entry in order to get it to work.

As this is an upgrade try deleting an entry and recreating it as a native SME6 entry and see if it behaves differently!

HTH

Charlie Brady

Reverse DNS from hosts table? (Re: DNS Issue)
« Reply #4 on: January 31, 2004, 08:12:07 PM »
Quote from: "Graeme Fleming"
Version 6 uses TinyDNS not Bind and my guess is that they behave slightly differently (or SME handles them differently)


Correct.

Quote
- you may need to add the MAC address for the client NIC to the matching hostname entry in order to get it to work.

As this is an upgrade try deleting an entry and recreating it as a native SME6 entry and see if it behaves differently!


No, none of those will help.

This code in the /var/service/tinydns/root/data/00_functions template is key:

Code: [Select]

    sub get_reverse_lookup_choices
    {
        my %reverse_lookups = ();
        foreach my $host ($hosts->hosts())
        {
            # A remote host must be a DNS alias.
            next if $host->prop('HostType') eq 'Remote';

            my $alias = $host->prop('ReverseDNS') || "no";
            if ($alias eq "yes")
            {
                # This host is not a DNS alias, so we should make note of it
                # for reverse DNS lookup purposes.
                my $ip = host2ip($host);
                $reverse_lookups{$ip} = $host->{key};
                # Note: Here we clobber any existing key/value pair, so if
                # there is more than one host with the same ip flagged as
                # being the reversedns host, the last one entered in this hash
                # will win. Don't do that. ;-)
            }
        }
        return %reverse_lookups;
    }


Looks to me as though creating a "ReverseDNS" property with value of "yes" for each hostname you want to show up in reverse DNS will do what you want:
Code: [Select]

/sbin/e-smith/config hosts setprop xxxx.your.domain ReverseDNS yes
/sbin/e-smith/signal-event host-modify xxx.your.domain


Either that or change the default from '|| "no"' to '|| "yes"' in the template. Try that in a custom template. If you're happy with the result, pass on the problem and solution to the bugs forum.

Charlie