The steps I go through in order to configure bind9 are as follows:
Run the "sudo gedit /etc/bind/named.conf.options" command to edit the file and add the "response-policy { zone "bind-blocked-domains.rpz" ; };" line at the end of the file then save.
Run the "sudo gedit /etc/bind/named.conf.default-zone" command to edit the file and add the following lines at the end of the file and save it.
zone "bind-blocked-domains.rpz" IN {
type master;
file "/etc/bind/blocked-domains.rpz";
};
Run the "sudo gedit /etc/bind/blocked-domains.rpz" command to create a new file and edit it and add the following lines:
$TTL 2h ; default TTL
@ IN SOA localhost. root.localhost. (
2 ; serial
3H ; refresh
1H ; retry
1W ; expiry
1H) ; minimum
IN NS localhost.use-application-dns.net CNAME .
*.use-application-dns.net CNAME .
Run the "sudo gedit /etc/resolv.conf" command to edit the file and make sure the "nameserver 127.0.0.1" line is present. (at this point, no matter how many times I reconfigured, the address always ends in 53 instead of .01)
In the terminal, run the following command:
nslookup use-application-dns.net
Server: 127.0.0.1
Address: 127.0.0.1#53
(regardless if manually change the adress to end in 1 or in 53 and run this command, the terminal simply does not respond in any way)
[Notes]:
I also tried the following methods in order to troubleshoot the configuration with no success:
Flush DNS cache:
sudo systemd-resolve --flush-caches
Add this line to the end of the file /etc/dhcp/dhclient.conf (use "sudo gedit /etc/dhcp/dhclient.conf to edit the file):
supersede domain-name-servers 127.0.0.1
Then renew your DHCP lease:
sudo dhclient -r
Check the DNS server your system is using and make sure it is 127.0.0.1:
[Affected Platforms]:
The steps I go through in order to configure bind9 are as follows:
Run the "sudo gedit /etc/bind/named.conf.options" command to edit the file and add the "response-policy { zone "bind-blocked-domains.rpz" ; };" line at the end of the file then save.
Run the "sudo gedit /etc/bind/named.conf.default-zone" command to edit the file and add the following lines at the end of the file and save it.
zone "bind-blocked-domains.rpz" IN { type master; file "/etc/bind/blocked-domains.rpz"; };
$TTL 2h ; default TTL @ IN SOA localhost. root.localhost. ( 2 ; serial 3H ; refresh 1H ; retry 1W ; expiry 1H) ; minimum IN NS localhost.use-application-dns.net CNAME . *.use-application-dns.net CNAME .
Run the "sudo gedit /etc/resolv.conf" command to edit the file and make sure the "nameserver 127.0.0.1" line is present. (at this point, no matter how many times I reconfigured, the address always ends in 53 instead of .01)
In the terminal, run the following command:
nslookup use-application-dns.net Server: 127.0.0.1 Address: 127.0.0.1#53 (regardless if manually change the adress to end in 1 or in 53 and run this command, the terminal simply does not respond in any way)
[Notes]:
supersede domain-name-servers 127.0.0.1
Then renew your DHCP lease: sudo dhclient -r
sudo systemd-resolve --status