« Generating POT files for WordPress plugins | Home | Scanning with Brother DCP-7065DN in Ubuntu »
Simple recursive DNS server with Unbound DNS
By admin | July 30, 2020
This is a simple configuration for running a recursive DNS server (passes DNS requests to another server and caches responses) with the Unbound DNS server.
Installation (Ubuntu):
sudo apt-get install -y unbound
Open the config
sudo vim /etc/unbound/unbound.conf
Configuration
Replace 8.8.8.8 below with the desired upstream DNS server.
# The following line includes additional configuration files from the # /etc/unbound/unbound.conf.d directory. #include: "/etc/unbound/unbound.conf.d/*.conf" # NOTE: needed to comment out the above line avoid a "status: SERVFAIL" response server: # Enable verbose debugging messages verbosity: 1000 # Run on all interfaces interface: 0.0.0.0 # Hide the server name and version hide-identity: yes hide-version: yes # Who should be able to query the server access-control: 0.0.0.0/0 allow do-ip4: yes do-ip6: no do-udp: yes # Enable this to support TCP DNS which is required in some applications do-tcp: yes # Allow forwarding to another 127.0.0.0/8 DNS server (e.g. another local dnsmasq or systemd-resolve) do-not-query-localhost: no forward-zone: name: "." # Replace 8.8.8.8 with your desired upstream DNS server # You can have multiple forward-addr lines forward-addr: 8.8.8.8@53
Starting the server
sudo systemctl restart unbound
Debugging / Troubleshooting
Query the server
dig @your_server_here example.com
Read the DNS server log
sudo systemctl status unbound -n 50
References:
If you found this article helpful or interesting, please help Compdigitec spread the word. Don’t forget to subscribe to Compdigitec Labs for more useful and interesting articles!
Topics: Linux | 25 Comments »
February 12th, 2022 at 02:52
… [Trackback]
[…] Find More on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
March 14th, 2022 at 14:37
… [Trackback]
[…] Read More Info here on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
March 22nd, 2022 at 23:42
… [Trackback]
[…] Read More on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
April 22nd, 2022 at 18:57
… [Trackback]
[…] Find More here to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
April 30th, 2022 at 19:12
… [Trackback]
[…] Here you will find 88591 additional Info to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
June 21st, 2022 at 09:34
… [Trackback]
[…] Find More here on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
June 24th, 2022 at 14:50
… [Trackback]
[…] Read More to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
August 8th, 2022 at 19:57
… [Trackback]
[…] There you can find 56202 more Info on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
August 21st, 2022 at 09:46
… [Trackback]
[…] Read More here on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
August 28th, 2022 at 10:14
… [Trackback]
[…] Find More on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
September 27th, 2022 at 13:23
… [Trackback]
[…] Find More Information here to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
October 25th, 2022 at 04:00
… [Trackback]
[…] Find More Information here on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
October 26th, 2022 at 01:34
… [Trackback]
[…] Find More to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
November 4th, 2022 at 03:33
… [Trackback]
[…] Info to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
December 7th, 2022 at 03:20
… [Trackback]
[…] Read More on on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
December 17th, 2022 at 17:55
… [Trackback]
[…] Find More here on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
December 29th, 2022 at 03:10
… [Trackback]
[…] There you will find 77866 more Info on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
January 6th, 2023 at 00:12
… [Trackback]
[…] Find More on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
January 11th, 2023 at 10:59
… [Trackback]
[…] Here you can find 85467 more Information to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
January 20th, 2023 at 16:02
… [Trackback]
[…] Info on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
January 26th, 2023 at 16:51
… [Trackback]
[…] There you can find 40856 more Info on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
February 1st, 2023 at 03:45
… [Trackback]
[…] Find More on on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
February 3rd, 2023 at 19:01
… [Trackback]
[…] Read More Information here to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
March 8th, 2023 at 23:44
… [Trackback]
[…] There you will find 9280 more Information on that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]
March 23rd, 2023 at 19:24
… [Trackback]
[…] Information to that Topic: compdigitec.com/labs/2020/07/30/simple-recursive-dns-server-with-unbound-dns/ […]