What happened to named.conf in ISC BIND DNS on Fedora 7?

I’ve made the great leap this week by moving to a new colocation. This site and many others have moved to a new dedicated server because the old service I used provided by unnamed company was absolutely horrible. They boasted 99.99% uptime, HA! I was lucky to get 75% uptime out of those fools for the year I was with them. Anyway…

The one thing I hate about moving is having to transfer gigs of data and reconfigure things. To cut it short, the old server was Fedora Core 4 and the new server is Fedora 7. Changes have been made between the three versions difference. One of these changes explains the title of this post. What happened to named.conf?

I checked the typical locations like /etc and /var/named/chroot/etc but it was nowhere to be found. I ran a locate and it didn’t exist. Thinking it was somewhat possible that maybe it was in a RPM I hadn’t installed, I checked the RPM list on a Fedora mirror site and compared those to the RPM’s I did have installed. No luck, everything was there.

I searched the net and didn’t find any reason for named.conf’s disappearance. I also discovered I wasn’t the only one seeking an explanation to its vanishing act. I came across a post on a forum mentioning the use of system-config-bind to create named.conf. A marvel idea, however it’s a GUI based tool and that leaves us text based users out in the cold — well sort of…

If you’re like me and want to set up a DNS Server on Fedora 7 to handle your zones, then follow these steps while as root.

1. Even though it’s a GUI dependent tool, install system-config-bind using yum. It contains template files you can use to get named up and running.

yum install system-config-bind

2. The templates used by system-config-bind for generate named.conf and other essential files have been installed in /usr/share/system-config-bind/profiles/default. We need to copy these files to where named would be expecting them (the assumption being that you’re running named in a chroot jail.

cd /usr/share/system-config-bind/profiles/default
cp -p named.conf /var/named/chroot/etc/
cp ./named/* /var/named/chroot/var/named/

3. Now that named.conf is copied over we’ll need to make a change to the root hints file name. Right now our named.conf is looking for the file named.root instead of named.ca as in prior releases of bind. If you don’t make this change, named will fail to start and you’ll get an error like this in syslog named[20622]: could not configure root hints from ‘named.root’: file not found. Open named.conf in a text editor and look for this section (it should be right below options).

zone "." IN {
        type hint;
        file "named.root“;
};

Change named.root to named.ca and save your changes.

4. Create a symlink to named.conf in /etc (optional but suggested).

ln -s /var/named/chroot/etc/named.conf /etc/named.conf

5. Start the named service and you’re good to go.

service named start

Now go ahead and create your zone files and add their references to named.conf. See my RedHat Bind Tutorial on XenoCafe for more information on DNS and Zones.


One Response to “What happened to named.conf in ISC BIND DNS on Fedora 7?”

  1. stevenstromer Says:

    Hi,

    Great article. I think I might be the person who posted the idea of using system-config-bind to generate the zone files in the bind mailing list. Now, working on a bunch of remote servers, I was looking around to see if Fedora Core 8, and the newest version of bind, has resolved the problem (it hasn’t been resolved) and came across your excellent site.

    With a bit of experimentation, I’ve learned that bind-chroot takes its .conf and zone files from the existing bind configuration. So, to be slightly more syntactically consistent (and also to point out that these files have to be properly permissioned for security purposes), I’m offering the following slight revision:

    yum install system-config-bind (Do not install bind-chroot, yet.)
    mv /etc/named.conf /etc/named.orig
    cd /usr/share/system-config-bind/profiles/default
    cp -p named.conf /etc/
    chmod 640 /etc/named.conf
    cp ./named/* /var/named/
    chmod 640 /var/named/named*
    chmod 640 /var/named/local*
    vim /etc/named.conf (change named.root to named.ca)
    yum install bind-chroot

    All of the files and settings will be copied from the standard bind configuration to the jailed configuration. Looking forward to future collaboration!

    Best,
    Steven Stromer

Leave a Reply

You must be logged in to post a comment.