Knot DNS - DNS autoritaire haute performance
Find a file
2017-03-25 13:15:24 -05:00
doc Merge branch 'kdig_nocrypto' into 'master' 2017-03-20 16:09:42 +01:00
libtap contrib: move open_tmp_file from zonefile 2016-11-24 10:01:13 +01:00
m4 libknot: exported dynamic symbols cleanup 2016-12-09 16:29:29 +01:00
python python/libknot: encode stats values as integer 2017-02-10 09:11:36 +01:00
samples keymgr: add 'zone key ds' into completion 2015-08-27 16:33:04 +02:00
scripts timers: store also XFER timer 2016-10-23 08:21:52 +02:00
src zscanner: upgrade to Ragel 6.10 2017-03-24 13:18:04 +01:00
tests Merge branch 'dynarray_improvements' into 'master' 2017-03-24 13:04:23 +01:00
tests-extra tests-extra: update zone expiry timer in zone/older_soa 2017-03-23 12:53:48 +01:00
tests-fuzz Get src/utils/knotd/main.c correctly from $(top_srcdir) 2017-01-11 12:19:01 +01:00
.dir-locals.el added surmised C indentation rules for emacs users 2017-03-25 13:15:24 -05:00
.gitattributes Add .gitattributes export-ignore 2011-11-02 14:58:23 +01:00
.gitignore python: add Makefile to distribute the scripts 2016-12-29 15:52:21 +01:00
.gitlab-ci.yml Add missing apt-get update 2017-02-10 13:24:52 +01:00
.ycm_extra_conf.py Merge branch 'master' into 'events-refactor' 2017-01-16 15:04:07 +01:00
AUTHORS AUTHORS: remove contact e-mails 2016-01-11 10:27:53 +01:00
autogen.sh add autogen.sh 2014-12-17 14:14:56 +01:00
ChangeLog First try at autotools 2011-02-25 15:26:15 +01:00
configure.ac ctl: remove running from status with arguments, fix snprintf err return 2017-03-20 15:02:09 +01:00
COPYING Add OpenSSL linking exception to the copyright file 2011-11-02 23:23:31 +01:00
coverity_model.c Add an empty Coverity modeling file as a base 2014-04-07 10:27:16 +02:00
Doxy.page.h Various spelling and typo fixes 2014-03-24 09:43:16 +01:00
Doxyfile Doxyfile: ignore lmdb 2016-08-02 16:27:40 +02:00
Knot.config Project files updates + doxygen fixes 2014-11-07 09:46:57 +01:00
Knot.creator Added QtCreator project files 2011-02-28 11:19:59 +01:00
Knot.files events+ctl: freeze-thaw events implemented 2017-03-08 21:51:35 +01:00
Knot.includes keymgr: add config and confdb parameters 2016-06-27 10:56:59 +02:00
KNOWN_ISSUES doc: insert supported classes info from KNOWN_ISSUES 2014-08-20 16:07:11 +02:00
Makefile.am python: add Makefile to distribute the scripts 2016-12-29 15:52:21 +01:00
NEWS Prepare for next release 2017-02-13 09:59:42 +01:00
README Merge branch 'master' into 'events-refactor' 2017-01-16 15:04:07 +01:00
THANKS Clean project directory 2013-10-01 14:19:49 +02:00

Dependencies
============

Knot DNS has several dependencies:
* libtool
* autoconf > 2.65
* pkg-config
* liburcu >= 0.5.4
* gnutls >= 3.0
* jansson >= 2.3
* libedit

Embedded libraries:
* lmdb               (system library is preferred)

Optional packages:
* libcap-ng >= 0.6.4 (for POSIX 1003.1e capabilities(7))
* libidn             (for IDNA2003 support in Knot utilities)
* libsystemd         (for systemd init system support)

Dependencies for building documentation:
* python-sphinx

Installation
============

Knot DNS may already be included in your operating system distribution and
therefore can be installed from packages (Linux), ports (BSD) or via
Homebrew (Mac). This is always preferred unless you want to test the latest
features, contribute to Knot development, or you just know what you are doing.

Following sections describe how to build Knot DNS from the source code.

1) Install prerequisites

Debian based distributions
--------------------------
Update the system:
$ sudo apt-get update
$ sudo apt-get upgrade

Install prerequisites:
$ sudo apt-get install \
  libtool autoconf make pkg-config liburcu-dev libgnutls28-dev libjansson-dev libedit-dev

Install optional packages to override embedded libraries:
$ sudo apt-get install liblmdb-dev

Install optional packages:
$ sudo apt-get install libcap-ng-dev libsystemd-dev libidn11-dev protobuf-c-compiler libfstrm-dev

Fedora like distributions
-------------------------
Update the system:
# dnf upgrade

Install basic development tools:
# dnf install @buildsys-build

Install prerequisites:
# dnf install \
  libtool autoconf pkgconfig automake userspace-rcu-devel gnutls-devel jansson-devel libedit-devel

Install optional packages to override embedded libraries:
# dnf install lmdb-devel

Install optional packages:
# dnf install libcap-ng-devel systemd-devel libidn-devel protobuf-c-devel fstrm-devel

When compiling on RHEL based system, the Fedora EPEL repository has to be
enabled. Also for RHEL 6, forward compatibility package gnutls30-devel
with newer GnuTLS is required instead of gnutls-devel.

2) Install Knot DNS

Knot DNS requires compiler to support atomic intrinsics.
GCC version at least 4.1 supports legacy atomic builtins, however 4.7
or newer is preferred. Clang supports atomics since version 2.9.

Get the source code:
$ git clone git://git.nic.cz/knot-dns.git
Or extract source package to knot-dns directory

Compile Knot
$ cd knot-dns
$ autoreconf -if
$ ./configure
$ make

Install Knot DNS into system:
$ sudo make install
$ sudo ldconfig

NOTE: If you want to reduce zscanner compile time, use configure option --disable-fastparser.

Running
=======

1) Each server needs configuration file. Please see samples/knot.sample.conf,
project documentation, or man 5 knot.conf for more details.
Configuration file has to specify:
- storage for PID files, journal files etc.
- network interfaces
- served zones

E.g. use the default config file:
$ cd /etc/knot
$ mv knot.sample.conf knot.conf
Modify the config:
$ editor knot.conf

2) Prepare working directory
$ mv example.com.zone /var/lib/knot/

3) Start the server. This can be done by running the 'knotd' command.
Alternatively, your distribution should have an init script available, if you've
installed Knot using a binary package.

Start Knot in the foreground to see if it runs:
$ knotd -c myserver.conf

For more information, refer to the user manual or:
$ knotc -h
$ knotd -h

Join the chat at https://gitter.im/CZ-NIC/knot