BIND DNS Server Configuration, I'm Lost

I hope you will forgive me for thinking that setting up a DNS server should be easy. It turns out to be quite difficult ... especially if you've never done it before.

To reiterate a bit, I previously asked if anyone could recommend a personal DNS server for Windows XP for use in a development project.

My main desire is to host a DNS server that presents the following lookup table:

 Address          | IP
------------------+--------------
 *.devdomain1.dev | 192.168.10.2
 *.devdomain2.dev | 192.168.10.2

      

Do you know how to set this up in BIND 9? Or maybe there is an easier solution that I forgot. I know I could add individual subdomains to my HOSTS file, but since we have many subdomains that need to be supported across multiple dev machines, I would rather have a simple template.

+1


source to share


2 answers


A zone file like this should suffice (on my system this will be in / etc / bind / zones / devdomain 2.dev.hosts)

devdomain2.dev. IN SOA localhost. johannesh.devdomain2.dev. (
        1102522753
        10800
        3600
        604800
        38400
)

devdomain2.dev.    IN      NS     localhost.
*.devdomain2.dev.   IN      A      192.168.10.2

      

Then my /etc/bind/named.conf.local referenced it like this



zone "devdomain2.dev" {
        type master;
        file "/etc/bind/zones/devdomain2.dev.hosts";
};

      

(Note that you can fully adapt this domain-only .dev pattern, or configure a different zone for devdomain1)

+2


source


How far do you have?



You can just create a zone for .dev and use a wildcard

+1


source







All Articles