Setting Up a Forwarding DNS Server on DEBIAN


SUBMITTED BY: benk2x

DATE: Jan. 30, 2020, 9:19 a.m.

FORMAT: Text only

SIZE: 2.0 kB

HITS: 720

  1. INSTALL REQUIREMENTS
  2. apt-get install bind9 bind9utils
  3. EDIT CONFIG FILE BASED /etc/bind/named.conf.options
  4. PREPAND
  5. >> acl allowed_clients {
  6. >> localhost;
  7. >> 10.42.0.0/24;
  8. >> };
  9. UNCOMMENT SECTOR forwarders TO
  10. >> forwarders {
  11. >> 1.1.1.1;
  12. >> 1.0.1.0;
  13. >> };
  14. >> recursion yes;
  15. >> allow-query { allowed_clients; };
  16. >> forward only;
  17. OUR NEW FILE SAVED AS named.conf.options
  18. --------------------------------------
  19. acl allowed_clients {
  20. localhost;
  21. 10.42.0.0/24;
  22. };
  23. options {
  24. directory "/var/cache/bind";
  25. // If there is a firewall between you and nameservers you want
  26. // to talk to, you may need to fix the firewall to allow multiple
  27. // ports to talk. See http://www.kb.cert.org/vuls/id/800113
  28. // If your ISP provided one or more IP addresses for stable
  29. // nameservers, you probably want to use them as forwarders.
  30. // Uncomment the following block, and insert the addresses replacing
  31. // the all-0's placeholder.
  32. forwarders {
  33. 8.8.8.8;
  34. 8.8.4.4;
  35. };
  36. recursion yes;
  37. allow-query { allowed_clients; };
  38. forward only;
  39. //========================================================================
  40. // If BIND logs error messages about the root key being expired,
  41. // you will need to update your keys. See https://www.isc.org/bind-keys
  42. //========================================================================
  43. dnssec-validation auto;
  44. auth-nxdomain no; # conform to RFC1035
  45. listen-on-v6 { any; };
  46. };
  47. ------------------------------------------------
  48. CHECKING BIND CONFIG
  49. named-checkconf
  50. systemctl restart bind9
  51. systemctl status bind9
  52. ||||||||
  53. Testing Out DNS Server on Client System
  54. https://www.unixmen.com/setting-forwarding-dns-server-debian/

comments powered by Disqus