<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.ampr.org/w/index.php?action=history&amp;feed=atom&amp;title=DNS%2FSetup%2FOpenBSD_Resolver</id>
	<title>DNS/Setup/OpenBSD Resolver - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.ampr.org/w/index.php?action=history&amp;feed=atom&amp;title=DNS%2FSetup%2FOpenBSD_Resolver"/>
	<link rel="alternate" type="text/html" href="https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;action=history"/>
	<updated>2026-05-07T08:56:30Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.42.3</generator>
	<entry>
		<id>https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=2490&amp;oldid=prev</id>
		<title>KI5QKX: mw push</title>
		<link rel="alternate" type="text/html" href="https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=2490&amp;oldid=prev"/>
		<updated>2026-04-30T18:52:37Z</updated>

		<summary type="html">&lt;p&gt;mw push&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 18:52, 30 April 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l120&quot;&gt;Line 120:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 120:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Congratulations!  You have set up a caching, validating, recursive resolver that can serve DNS to any machine on AMPRNet.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Congratulations!  You have set up a caching, validating, recursive resolver that can serve DNS to any machine on AMPRNet.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:How-To]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Reference]][[Category:How-To Guides]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Reference]][[Category:How-To Guides]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:DNS]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:DNS]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:DNS Setup]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:DNS Setup]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>KI5QKX</name></author>
	</entry>
	<entry>
		<id>https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=2341&amp;oldid=prev</id>
		<title>KI5QKX: mw push</title>
		<link rel="alternate" type="text/html" href="https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=2341&amp;oldid=prev"/>
		<updated>2026-03-01T00:14:31Z</updated>

		<summary type="html">&lt;p&gt;mw push&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 00:14, 1 March 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l122&quot;&gt;Line 122:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 122:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Reference]][[Category:How-To Guides]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Reference]][[Category:How-To Guides]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:DNS]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:DNS Setup]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>KI5QKX</name></author>
	</entry>
	<entry>
		<id>https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=1744&amp;oldid=prev</id>
		<title>KI5QKX: Moving OpenBSD resolver setup here from DNS/Overview</title>
		<link rel="alternate" type="text/html" href="https://wiki.ampr.org/w/index.php?title=DNS/Setup/OpenBSD_Resolver&amp;diff=1744&amp;oldid=prev"/>
		<updated>2026-02-04T22:30:19Z</updated>

		<summary type="html">&lt;p&gt;Moving OpenBSD resolver setup here from DNS/Overview&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Section nav&lt;br /&gt;
 | hub=DNS&lt;br /&gt;
 | title=DNS&lt;br /&gt;
 | category=DNS&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
= Setting Up a Recursive Resolver on OpenBSD =&lt;br /&gt;
&lt;br /&gt;
[https://www.openbsd.org OpenBSD] is a variant of Unix known for security and a focus on code correctness.  It also comes bundled with a high performance caching, validating, recursive DNS resolver package called [https://www.nlnetlabs.nl/projects/unbound/about/ Unbound]. Unbound is easily configured, we will give an example of doing so here.&lt;br /&gt;
&lt;br /&gt;
== Configuring the unbound server ==&lt;br /&gt;
&lt;br /&gt;
The first step is to configure the server by editing its configuration file, &amp;lt;code&amp;gt;/var/unbound/etc/unbound.conf&amp;lt;/code&amp;gt;.  The format and allowable settings in this file are given in the man page, [https://man.openbsd.org/unbound.conf &amp;#039;&amp;#039;unbound.conf&amp;#039;&amp;#039;(5)], but at a high level it contains several sections:&lt;br /&gt;
&lt;br /&gt;
* A &amp;lt;code&amp;gt;server:&amp;lt;/code&amp;gt; section allows us to set settings for the server itself.&lt;br /&gt;
* A &amp;lt;code&amp;gt;remote-control:&amp;lt;/code&amp;gt; section lets setup access for a control client.&lt;br /&gt;
* An arbitrary number of optional zone-specific sections that allow us to configure options for those zones.  This gives us the ability to forward to specific authoritative servers for a zone and so on.&lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s an example of what a configuration file might look like:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;server:&lt;br /&gt;
        interface: 0.0.0.0&lt;br /&gt;
        interface: ::0&lt;br /&gt;
&lt;br /&gt;
        access-control: 0.0.0.0/0 refuse&lt;br /&gt;
        access-control: ::0/0 refuse&lt;br /&gt;
&lt;br /&gt;
        access-control: 127.0.0.0/8 allow&lt;br /&gt;
        access-control: ::1 allow&lt;br /&gt;
&lt;br /&gt;
        access-control: 44.0.0.0/9 allow&lt;br /&gt;
        access-control: 44.128.0.0/10 allow&lt;br /&gt;
&lt;br /&gt;
        hide-identity: yes&lt;br /&gt;
        hide-version: yes&lt;br /&gt;
&lt;br /&gt;
        # Perform DNSSEC validation.&lt;br /&gt;
        auto-trust-anchor-file: &amp;quot;/var/unbound/db/root.key&amp;quot;&lt;br /&gt;
        val-log-level: 2&lt;br /&gt;
&lt;br /&gt;
        # Synthesize NXDOMAINs from DNSSEC NSEC chains.&lt;br /&gt;
        # https://tools.ietf.org/html/rfc8198&lt;br /&gt;
        #&lt;br /&gt;
        aggressive-nsec: yes&lt;br /&gt;
&lt;br /&gt;
        # Use TCP for &amp;quot;forward-zone&amp;quot; requests. Useful if you are making&lt;br /&gt;
        # DNS requests over an SSH port forwarding.&lt;br /&gt;
        #tcp-upstream: yes&lt;br /&gt;
&lt;br /&gt;
        # CA Certificates used for forward-tls-upstream (RFC7858) hostname&lt;br /&gt;
        # verification.  Since it&amp;#039;s outside the chroot it is only loaded at&lt;br /&gt;
        # startup and thus cannot be changed via a reload.&lt;br /&gt;
        #tls-cert-bundle: &amp;quot;/etc/ssl/cert.pem&amp;quot;&lt;br /&gt;
&lt;br /&gt;
remote-control:&lt;br /&gt;
        control-enable: yes&lt;br /&gt;
        control-interface: /var/run/unbound.sock&lt;br /&gt;
&lt;br /&gt;
stub-zone:&lt;br /&gt;
        name: &amp;quot;ampr.org.&amp;quot;&lt;br /&gt;
        stub-addr: 44.1.1.44&lt;br /&gt;
        stub-host: ns2.us.ardc.org&lt;br /&gt;
        stub-host: ns.ardc.org&lt;br /&gt;
        stub-host: ns1.de.ardc.org&lt;br /&gt;
        stub-host: a.gw4.uk&lt;br /&gt;
&lt;br /&gt;
stub-zone:&lt;br /&gt;
        name: &amp;quot;44.in-addr.arpa.&amp;quot;&lt;br /&gt;
        stub-addr: 44.1.1.44&lt;br /&gt;
        stub-host: ns2.us.ardc.org&lt;br /&gt;
        stub-host: ns.ardc.org&lt;br /&gt;
        stub-host: ns1.de.ardc.org&lt;br /&gt;
        stub-host: a.gw4.uk&lt;br /&gt;
        stub-first: yes&lt;br /&gt;
&lt;br /&gt;
stub-zone:&lt;br /&gt;
        name: &amp;quot;128.44.in-addr.arpa.&amp;quot;&lt;br /&gt;
        stub-addr: 44.1.1.44&lt;br /&gt;
        stub-host: ns2.us.ardc.org&lt;br /&gt;
        stub-host: ns.ardc.org&lt;br /&gt;
        stub-host: ns1.de.ardc.org&lt;br /&gt;
        stub-host: a.gw4.uk&lt;br /&gt;
        stub-first: yes&lt;br /&gt;
&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This configuration sets some non-default options in the &amp;lt;code&amp;gt;server:&amp;lt;/code&amp;gt; section, such as what interface to listen on for incoming connections, and options for what machines are allowed to send us queries.  Here, we listen on all addresses on all interfaces for both IPv4 and IPv6 and we allow any AMPRNet host to send us queries.&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;remote-control:&amp;lt;/code&amp;gt; section enables and configures a Unix domain socket that allows us to control the unbound daemon with the client control program, &amp;lt;code&amp;gt;unbound-control&amp;lt;/code&amp;gt;; this way, we can ask it for performance and usage statistics, force it to flush its cache, etc, without stopping and restarting it.&lt;br /&gt;
&lt;br /&gt;
The most interesting parts are the &amp;lt;code&amp;gt;stub-zone:&amp;lt;/code&amp;gt; sections.  These allow us to tell unbound about servers that are authoritative for particular zones, bypassing querying through the root for domains under those zones.  In the three sections given here, we tell it to query the ARDC-administered non-recursive authoritative servers for the &amp;#039;&amp;#039;ampr.org&amp;#039;&amp;#039;, &amp;#039;&amp;#039;44.in-addr.arpa&amp;#039;&amp;#039; and &amp;#039;&amp;#039;128.44.in-addr.arpa&amp;#039;&amp;#039; zones; that is, for anything related to AMPRNet, we forward directly to the authoritative servers.&lt;br /&gt;
&lt;br /&gt;
Note the &amp;lt;code&amp;gt;stub-first: yes&amp;lt;/code&amp;gt; lines for the two reverse domains: some reverse domains are &amp;#039;&amp;#039;delegated&amp;#039;&amp;#039; to other services.  This line says to try the ARDC servers first, and if those return an error, to perform the standard query from the root.&lt;br /&gt;
&lt;br /&gt;
Once the server is configured, we can enable it by adding a line to &amp;lt;code&amp;gt;/etc/rc.conf.local&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;unbound_flags=&amp;quot;&amp;quot;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, if we reboot, we will find the unbound daemon running the next time we login.  We should be able to direct DNS queries to the local server now, and we can edit the &amp;lt;code&amp;gt;/etc/resolv.conf&amp;lt;/code&amp;gt; file to include a reference to our unbound instance.  For example, our resolv.conf file might look something like:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;lookup file bind&lt;br /&gt;
domain your-call.ampr.org&lt;br /&gt;
search your-call.ampr.org ampr.org&lt;br /&gt;
nameserver 127.0.0.1&lt;br /&gt;
&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course, one likely wants to query one&amp;#039;s own callsign based subdomain, not &amp;quot;your-call&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Now, other machines can be configured to connect to your unbound instance.  Here is an example from a machine at KZ2X:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;lookup file bind&lt;br /&gt;
domain kz2x.ampr.org&lt;br /&gt;
search kz2x.ampr.org ampr.org&lt;br /&gt;
nameserver 44.44.48.29&lt;br /&gt;
nameserver 8.8.8.8&lt;br /&gt;
nameserver 1.1.1.1&lt;br /&gt;
&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that &amp;lt;code&amp;gt;44.44.48.29&amp;lt;/code&amp;gt; is the machine that runs unbound.&lt;br /&gt;
&lt;br /&gt;
Congratulations!  You have set up a caching, validating, recursive resolver that can serve DNS to any machine on AMPRNet.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Reference]][[Category:How-To Guides]]&lt;/div&gt;</summary>
		<author><name>KI5QKX</name></author>
	</entry>
</feed>