8
8
<i>This guide is for experienced UNIX/Linux/BSD users who just want to
9
9
quickly try out MaraDNS</i>
11
MaraDNS acts as both a recursive and an authoritative DNS server. In
12
other words, MaraDNS can both be used to speed up the internet, and/or
13
serve domains that you may have.
11
MaraDNS acts as an authoritative DNS server. Recursion is handled by
12
the included "Deadwood" program.
16
To try out MaraDNS as a recursive nameserver is easy:
15
To try out Deadwood as a recursive nameserver:
19
<li>Compile MaraDNS. Type in './configure; make' in the
18
<li>Compile MaraDNS and Deadwood. Type in './configure; make' in the
20
19
top-level MaraDNS directory.
21
20
Note: No need to compile if you downloaded a binary RPM or Debian package.
22
<li>The the file deadwood-{version number}/src/Deadwood and place it in
23
25
<li>Take the file server/maradns and place it in /usr/local/sbin
25
27
<li> Take the file tools/duende and place it in /usr/local/sbin
27
29
<li>Create an empty directory called /etc/maradns
29
<li>Create a mararc file. This file only needs to be three lines long
30
on systems with a /dev/urandom file, and four lines long on older
31
operating systems without /dev/urandom
31
<li>Create a dwood3rc file. This file only needs to be three lines long
32
on systems with a /dev/urandom file.
33
Here is a sample mararc file:
34
Here is a sample dwood3rc file:
35
36
ipv4_bind_addresses = "127.0.0.1"
36
37
chroot_dir = "/etc/maradns"
37
38
recursive_acl = "127.0.0.1"
39
This mararc file says that MaraDNS will have the ip "127.0.0.1" (this
40
This dwood3rc file says that MaraDNS will have the ip "127.0.0.1" (this
40
41
is the bind_address), run from the directory /etc/maradns (the chroot_dir
41
42
value), and only allow the ip "127.0.0.1" to make recursive queries (the
42
43
recursive_acl value).
44
<li>Place the mararc file in the location /etc/mararc on your system.
45
<li>Place the dwood3rc file in the location /etc/dwood3rc on your system.
46
<li>Run MaraDNS as a non-daemon:
47
<li>Run Deadwood as a non-daemon:
49
/usr/local/sbin/maradns
50
/usr/local/sbin/Deadwood
52
Since MaraDNS needs to bind to a privileged port (port 53), it needs
53
to start up running as root. MaraDNS is designed with security in mind, and
53
Since Deadwood needs to bind to a privileged port (port 53), it needs
54
to start up running as root. Deadwood is designed with security in mind, and
54
55
will drop root privileges before being visible to the public internet.
56
<li>Test MaraDNS in another window or virtual terminal
57
<li>Test Deadwood in another window or virtual terminal
73
<li>If this works, make MaraDNS run as a daemon:
74
<li>If this works, make Deadwood run as a daemon:
77
/usr/local/sbin/duende /usr/local/sbin/maradns
78
/usr/local/sbin/duende /usr/local/sbin/Deadwood
81
82
duende is a tool that daemonizes maradns; the daemonizer is a separate
84
<li>If this all works, install MaraDNS:
85
<li>If this all works, install MaraDNS and Deadwood:
93
It is also possible to set up MaraDNS as both an authoritative and recursive
94
name server with the same IP:
94
It is also possible to set up the program "maradns" as an authoritative
97
98
<li>Here is the MaraRC file:
99
100
ipv4_bind_addresses = "127.0.0.1"
100
101
chroot_dir = "/etc/maradns"
101
recursive_acl = "127.0.0.1"
103
103
csv2["example.com."] = "db.example.com"
110
110
(Yes, experienced DNS admins, you can have SOA, NS, MX, SRV, and any other
111
111
kind of DNS data stored in a csv2 zone file. Read the csv2 man page for
113
<li>Recursive queries will be resolved normally
114
113
<li>Queries for <tt>example.com</tt> will resolve to 10.1.2.3
116
115
<tt>name.example.com</tt> query will return a "this host does not exist"