Wednesday, November 9, 2011

Bind9 and DHCP3 on Ubuntu 10.04 LTS

We continue documentation of a full Linux server stack. You should consider testing this setup using an experimental network on VirtualBox.

Blackbox Bind9 Package

Make sure you've configured your /etc/apt/sources.list appropriately.

The Blackbox Bind9 package configures a bind9 server for Ubuntu 10.04 LTS. Combined with DHCP3, you'll be able to join machines to your network and have them resolve each other as well as external addresses.

The source code for this package is available on-line.

Begin with

$ sudo apt-get install bbbind9

You'll be asked a series of questions. bbbind9 will attempt to guess reasonable defaults for your settings. You can accept them by pressing [Enter]:

Enter the base domain that your DNS server will service.

base domain name { home.lan }: 

Enter the netmask for the network your server will manage (generally it's a /24)

static interface netmask { }:

Your DNS server should have a static ip address. All your other machines can have DHCP assigned addresses.

static ip assigned to bind9 server { }: 

These are the DNS servers you hit for machines outside your domain.

external dns forwarders {;; }: 

Network interface to which service binds.

interface to which static ip is assigned { eth0 }: 

Fully qualified name of this DNS server.

fully qualified name for dns host { stemcell.home.lan }: 

Email address of administrator. Note that this convention does not allow the @ symbol. hostmaster.home.lan should be read as hostmaster@home.lan This should be a mail alias, or a mailbox, where the person(s) maintaining DNS should read mail frequently. Any mail regarding the domain will be sent to the address listed here. The name need not be hostmaster, it can be your normal e-mail address, but the e-mail address hostmaster is often expected to work as well.

email address for hostmaster (no @ allowed, use .) { hostmaster.home.lan }: 

Gateway for the interface that has a static ip address.

static interface gateway { }: 

Subnet for which this DNS server provides naming services.

ip zone for dns domain { 10.0.2 }: 

To confirm everything is working properly, perform the following:


You should receive the results of a query against your new host:


Non-authoritative answer:

Blackbox DHCP3 Package

The Dynamic Host Configuration Protocol enables machines on your network to be automatically configured with IP addresses, DNS, and other features. The Blackbox package is configured to be installed on the same host as bbbind9.

Subnet for which the DHCP3 server will be handing out leases.

subnet of dhcp zone { }: 

DNS domain to be assigned to client.

base domain name { home.lan }: 

DNS server that clients use.

ip address for nameserver to grant to dhcp clients { }: 

Fully qualified name of DNS server (this host).

fully qualified name for dns host { stemcell.home.lan }: 

IP gateway assigned to clients.

gateway that dhcp clients will use { }: 

Pool of addresses handed out to clients. Enter ranges as a tuple ().

available dhcp pool { ('', '') }: 

Try adding a client to your network and confirm that its properties now point to your new Bind9 server and its address is from your DHCP3 address pool.

No comments: