Linux DDNS/DHCP/IPv6 question

OK, so I've been given the task of reworking our test lab network. I have some requirements, and some plans. Here is what I have to do:

1. a subnet and subdomain with Windows DNS, DDNS, and DHCP, with all these in IPv6 later on. Also, AD and WDS
2. a subnet and subdomain with Linux DNS, DDNS, and DHCP, with all these in IPv6 later on. Also, a PXE build system for Linux to replace the existing one
3. a fully isolated, unrouted subnet for background use, no DNS or DHCP required. Not even any management required.

I'm given these things:
1. 3 vlans from IT programmed into our switches, one of which is isolated, and three subnets designated to their respective vlans
2. IT will set up the subdomans under the names I give and make my servers the authorities for those subdomains
3. two Dell R310 with 2.93GHz Xeon processors and 16GB of memory, quad port network cards, dual port FC HBAs, and an external FC array running Windows 2008 R2 with HyperV

My skills:
1. Excellent Windows 2008 R2 and virtualization skills
2. Excellent hardware skills
3. Good, but not great, Cisco switch configuration skills
4. 15 years in IT, mostly in desktop support, but the last 2 years as the test lab admin
5. good learning curve, although I am getting older and am not as fast to learn as I once was, but I'm as good once as I ever was.

So, I have the Windows VM's up and running for one subdomain. I have the isolated subnet there, and the departments have their respective blocks of "replication" addresses they can use without stepping on each others' toes.

My problem is the Linux subnet. I've created the VM's, but I have been totally unable to get CentOS 6 installed on them. I finally stepped back and use CentOS 5.6, but now I am having problems getting DDNS. I have DNS and DHCP working, but no DDNS updating. I've used what came with CentOS, but it doesn't seem up to the task.

I did try using dnsmasq as a DHCP/DDNS server, but once configured, it refuses to run while the main DNS service is running, and it is just not capable of doing the standard DNS tasks required. I'm throwing that out the window.

Any suggestions for programs for this purpose, particularly with IPv6 capabilities that I can leave disabled or unconfigured for now and add later? (I'm waiting on IT to get my IPv6 routing prefixes.) I would prefer something with a Web interface or at least a GUI, for management, but I will do the whole test file editing if I have to.

I am willing to go with whatever free Linux distro I have to in order to get this done. Please keep in mind I am rather new at Linux, and I hate keyboard work. (My fingers have never worked very well, and frequently don't do what I tell them to do. Half the time I type Exchange, it comes out XEhcgne.) I'm very good with Windows and logical reasoning, but a lot of Linux/Unix just doesn't seem very logical to me. If it comes down to compiling a program, I will need step by step instructions. packaged apps are best.

Thank you in advance.
11 answers Last reply
More about linux ddns dhcp ipv6 question
  1. ok, I kind of found a way to do it, but only under IPv4. No IPv6 capabilities yet.

    2 VMs: one uses dnsmasq for DHCP, DDNS, and DNS forwarding, it forwards to the second, which provides static DNS, NTP, TFTP, and PXE boot services. Now someone just needs to write a version of dnsmasq that has IPv6 capabilities.

    Until then, I'll keep searching.
  2. Really? Nobody knows of a single program or group of programs that can handle this? Is Linux really this far behind in usability and function?
  3. I'd love to chip in but just don't have anything like this sort of environment to play with. I'd suggest that you need to be asking in an Enterprise Linux forum, Toms is really more of a hobby / home environment.

    I can't believe that CentOS would not allow you to do everything you're after doing, it's just not something many people here would have call to experiment with.
  4. Maybe post the same question in the Networking thread?
  5. "Now someone just needs to write a version of dnsmasq that has IPv6 capabilities."

    I thought that dnsmasq did handle IPv6. Perhaps I'm wrong.
  6. I had to check...

    From the Man page:

    Dnsmasq supports IPv6 for DNS and TFTP, but not DHCP.

    Emphasis mine.
  7. Ah - I missed the DHCP requirement for IPv6.

    I'm not quite sure why DDNS should be a problem. I use a FreeBSD setup with bind as the DNS server and it does DDNS OK. Not sure which DHCP server it is offhand, but it sends update requests to the DNS server. As far as I'm concerned you can't beat FreeBSD as a server.

    I'd recommend webmin to anyone wanting a GUI interface to the traditional UNIX server programs. It has modules to handle most of them (although for simple changes you can't beat vi). I'm afraid I'm not familiar with Centos.
  8. After much struggling, researching, and piecing things together, I finally found a way. Since nobody else has instructions on all this in one place, I'll post what I wrote for my company.

    Setting up DDNS and DHCP on one server in CentOS 5, basic instructions.
    This is a basic guide using CentOS 5 only. Other distributions have little quirks that make these instructions nearly invalid. This is a record of how I got to a working DHCP/DDNS server on my first success after many false starts.

    1. Run a basic level install of CentOS 5.7 X64 as a desktop installation, with PHP and all development tools and libraries, and disable SELinux and the firewall. (Yes, a desktop installation. This makes sure the GUI is fully functional, and doesn’t have conflicting server tools.) Create a user “dnsadmin” through first boot wizard.
    2. Log in as root for the first time
    3. Set the dnsadmin user as a member of the “adm” group
    4. Once logged in, run the terminal and run “yum update”.
    5. Run “yum install bind” and “yum install system-config-bind”
    6. Run “yum install dhcp” (this may tell you it is already installed. Don’t worry about it if it is.)
    7. Start the “named” service
    8. Install NoMachine from the rpms (desktop first, then node, then server)
    9. (preferably from your desk using NoMachine, logged in as dnsadmin) create a launcher for “system-config-bind”, named “DNS Configuration Tool”, and start it. This should create the basic zones and get everything started. Add any other servers you might need, even if they are in other subnets or subdomains, as a system can have many names for a single address.
    10. Save and close the DNS Configuration Tool
    11. Restart the “named” service
    12. Reopen the DNS Configuration Tool
    13. Create the new zone for the new DNS subdomain and create a new entry for the DNS server making sure to have it create the reverse lookup entry as well. Save and close again.
    14. Edit the /var/named/chroot/etc/named.conf (if the file is not there, check /etc) file to include the following entries in the sections for both your DNS subdomain and the reverse lookup for your DHCP range.
    allow-update { key rndckey; } ;
    notify yes;

    15. edit the /etc/dhcpd.conf file to include the following information. (Things in parentheses are for you to fill in info. There are no parentheses in the configuration file, only braces {}. Also, feel free to replace the spaces between the variable and the value with as many tabs as it takes to line them up for easier editing later.)
    # DDNS settings section
    server-identifier (server name);
    ddns-updates on;
    ddns-update-style interim;
    ddns-domainname “(domain name with a ‘.’ at the end)”;
    ddns-rev-domainname “”;
    ignore client-updates;
    include “/var/named/chroot/etc/rndc.key”
    zone (domain name with a ‘.’ at the end) {
    key rndckey;

    # normal DHCP options
    option domain-name “(domain name)”;
    option domain-name-servers (DNS server IP address);
    option ntp-servers (NTP server address);
    option netbios-node-type 8;
    default-lease-time (desired lease time in seconds);
    max-lease-time (double desired lease time in seconds);

    # lease settings section
    subnet (the beginning of the IP address range) netmask (netmask) {
    range dynamic-bootp (first DHCP address in range) (last DHCP address in range);
    option broadcast-address (last address in subnet that ends in 255);
    option routers (gateway for this subnet);
    allow unknown-clients;
    zone (reverse DNS lookup zone) {
    primary (DNS server address);
    key rndckey;
    zone (domain name with a ‘.’ at the end) {
    primary (DNS server address);
    key rndckey;

    # Static DHCP reservations section
    # use this format when adding machines
    # host (system name) {
    # hardware Ethernet (system MAC address);
    # fixed-address (desired IP address, does not have to be within the DHCP range);
    # next-server (name or IP address of PXE boot server);
    # filename “pxelinux.0”;
    # }

    16. Start the “dhcpd” service and see if it runs. If it fails, begin troubleshooting the dhcpd.conf file. The most likely failures are in the key name (listed in the key file referenced in the DDNS update section) or the location of the key file or you may have forgotten an semicolon. There is also the possibility the rndc.key file is in /etc instead of /var/named/chroot/etc. The system log is very helpful in this, as it will tell you exactly where it found a problem, most of the time.
    17. Test with two DHCP machines and make sure they resolve each others’ names in IPv4. (ping (system name) -4)
    18. If everything comes up, congratulations. If not, search Google for possible solutions.

    BTW, I posted this in the Linux forum rather than the networking forum because Linux experts would be the only ones who could help. In the end, I found parts of the answers on other Linux forums, but nothing all in one place.

    The components I used were built into CentOS, and therefore RHEL as well, and can be adapted to serve for IPv6 with minor adjustments to the BIND9 server configuration and using the DHCP6 server that is also included in CentOS and RHEL. From what I have heard, other distros work fairly much the same way, with some adjustments. I actually gleaned some of this info from a Debian forum post, and still other information from a Ubuntu post, and "adjusted" it for CentOS.

    I hope this will help someone else who is searching for this same info, so they don't have to search for weeks like I did.

    Good luck out there all. It's a difficult world with Linux.
  9. Many thanks for sharing your findings and sorry we couldn't be of more help. There are a couple of old faces that might have known but alas, they are both MIA.

    Google does index this section (it's the first result for IDM Linux!) so hopefully others might find it. Could be worth posting it on CentOS forums too though as it stinks of the sort of thing people would be trying to do if more of them used IPv6.
  10. Actually, I did. I posted the question the day after I posted it here, and posted the answer as soon as I figured it out. So they'll have it.
  11. Should have guessed given you took the time to write the process for work ;-)

    Now if only the users would read those instructions developers cunningly hide behind the F1 key on the Windows software I was supporting....
Ask a new question

Read More

DHCP Ipv6 Linux