Solaris 10 DNS Oops! WTF?! Oh Yeah!

When building Solaris 10 servers in bulk.. That is 1 or more at a time. I usually don’t enable any sort of name resolution until later.

That’s the problem. When later rolls around, I’ve forgotten that I hadn’t enabled anything.

This would be fine and dandy if nslookup or host would let me know that my /etc/nsswitch.conf is only looking at files. It ignores that and goes strictly with what is in /etc/resolv.conf seemingly. So if that’s broke or incorrect it will, at least, tell you that.

Anyway, the system I have come up with to quickly check if nsswitch.conf is setup for DNS is to ssh to a know hostname. If this fails, it usually means you need to copy nsswitch.dns over nsswitch.conf.

Another gotcha that gets me.

Hits: 27

Bind9: Master Only

Configuration for a master only DNS server.

1. WILL NOT answer queries
2. WILL NOT forward queries
3. WILL NOT perform recursion
4. WILL allow transfers from specified slaves

Zone and configuration files are backed up disk to disk via rsync.

Single point editing of our name space.

Single point of failure. If server is lost, updates to DNS cannot be made until another master is brought online.

options {
directory “/etc”;
pid-file “/var/run/”;
version “Windows 3.11”;
allow-query {“none”; };
allow-recursion {“none”; };
notify yes;
also-notify {
allow-transfer {

zone “” {
type master;
file “/etc/”;

Hits: 61

FTP Reporting Unknown Host

So, I’m staring the problem in the face for quite some time (though it’s probably obvious to those that have encountered it before.)

Test server #1: Redhat 9
Test server #2: Redhat 7.1

Both in the same network segment.
Both using the same DNS servers.

Let the hilarity ensue!

On #1:
host reports fine
ftp connects fine

On #2:
host reports fine
ftp reports Unknown Host

Figured it was a configuration file, but wasn’t sure which one. Finally found the answer to my problem on a Solaris site. Theres one for google-fu, leave off the operating system next time.

The line in /etc/nsswitch.conf on #1 looked like such:
hosts: files dns

The line in /etc/nsswitch.conf on #2 looked like such:
hosts: files

How on earth the host command was able to do a successful lookup is beyond me. Unless it’s hard-coded not to use /etc/hosts.

Can anyone confirm whether or not it is?

Hits: 13