User Tools

Site Tools



Install Bind, webserver with PHP and MySQL. For example on Debian:

lighttpd php5-cgi mysql-server php5-mysql bind9


Convince someone to forward a NS subdomain to you. For example:

dyn     IN   A     your.ip.address
d       IN   NS    dyn

Configure Bind

You need to configure a zone. If you don't have any, you can use example config files

  • named.conf.local - zone inclusion
  • - zone specification
  • - example zone (of course change it to your needs)

After configuration, your nameserver should be able to respond to “A” query.

We need to generate a user key that we will sign the updates with (with this you can also securely update a remote DNS server).

dnssec-keygen -a HMAC-SHA1 -b 160 -n USER

Two files are generated, K*key and K*private. Take the key from the *key one and put it to zone declaration ( in our case)

Configure dynamic updater

Put scripts from the shell/ directory somewhere. Edit

Try update with

echo test a | bash -x

. You should be then able to resolve “A test.your.domain.” to

On Debian I had a problem that the /etc/bind directory was not owned by the user under which bind is running, so bind was unable to perform the update

Some security

The key should not be world-readable. You can create a separate user, chown & chmod 600 the key and all the scripts and then use the example sudoers file to run the update under that user.

Web frontend

Create a MySQL database. I use Adminer GUI, but if you want to go with the command line, it will be something like this


GRANT ALL PRIVILEGES ON `kiviak`.* TO 'kiviak'@'localhost';

Then execute schema.sql to create the table.

Point your webserver to files in web/ folder. These files don't have to be writable by the webserver.

Edit config.php to reflect your environment.



The delete.php script deletes hostnames that have not been updated for more than a month. You can add it to your crontab.

kiviak-install.txt · Last modified: 2015-02-07 20:55:28 (external edit)