DNS mit unbound.page 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  1. ---
  2. format: markdown
  3. title: Bildungskurs Freifunk
  4. categories: Treffen
  5. ...
  6. # Installation
  7. - Wird an anderer Stelle des Wiki beschrieben
  8. # Allgemein
  9. - Als Nameserver im weiteren NS genannt, kommen nsd und unbound zum Einsatz.
  10. Auf nordstadt und hoerde ist freeBSD im Einsatz, auf den APUs Debian.
  11. Durch die unterschiedliche Verzeichnisstruktur befinden sich die Konfigurationsdaten in verschiedenen Verzeichnissen:
  12. freeBSD: /usr/local/etc/nsd und /var/unbound
  13. Debian: nicht installiert und /etc/unbound und /var/lib/unbound
  14. Überblick nsd ./. unbound:
  15. ................nsd...................unbound
  16. nordstadt...193.43.220.129...193.43.220.161
  17. hoerde......130.180.53.22.....193.43.220.136, 193.43.220.168
  18. Zur Steuerung gibt es **nsd-control** und **unbound-control**. Bei freeBSD **local-unbound-control**.
  19. ## Der primäre NS (nsd) auf nordstadt hält die aktuellen Zonendateien vor
  20. - ***ffdo.net*** für die Auflösung Name -> IP
  21. - ***220.43.193.in-addr.arpa*** für reverse mapping ip -> Name für 193.43.220.
  22. - ***221.43.193.in-addr.arpa*** für reverse mapping ip -> Name für 193.43.221.
  23. Die sekundären NS (nsd und unbound) erhalten diese Zonendateien vom primären NS.
  24. Die Zonendaten können mit
  25. **nsd-checkconf** -p 220.43.193.in-addr.arpa 220.43.193.in-addr.arpa
  26. **nsd-checkconf** -p 221.43.193.in-addr.arpa 221.43.193.in-addr.arpa
  27. **nsd-checkconf** -p ffdo.net ffdo.net
  28. geprüft werden.
  29. Die hier verwendeten Adressen sind größtenteils dem Wiki [IP-Adressen](IP-Adressen) entnommen.
  30. # Nordstadt
  31. ## Datei /var/unbound/unbound.conf
  32. # This file was generated by local-unbound-setup.
  33. # Modifications will be overwritten.
  34. server:
  35. username: unbound
  36. directory: /var/unbound
  37. chroot: /var/unbound
  38. pidfile: /var/run/local_unbound.pid
  39. use-syslog: yes
  40. auto-trust-anchor-file: /var/unbound/root.key
  41. interface: 127.0.0.1
  42. interface: ::1
  43. interface: 193.43.220.161
  44. access-control: 127.0.0.1/32 allow
  45. access-control: ::1 allow
  46. access-control: 193.43.220.0/23 allow
  47. access-control: 91.204.4.0/22 allow
  48. access-control: 192.168.0.0/16 allow
  49. access-control: 0.0.0.0/0 refuse_non_local
  50. #val-permissive-mode: "yes"
  51. ## Datei /var/unbound/conf.d/control.conf
  52. # This file was generated by local-unbound-setup.
  53. # Modifications will be overwritten.
  54. remote-control:
  55. control-enable: yes
  56. control-interface: /var/run/local_unbound.ctl
  57. control-use-cert: no
  58. ## Datei /var/unbound/conf.d/lan-zones.conf
  59. # This file was generated by local-unbound-setup.
  60. # Modifications will be overwritten.
  61. server:
  62. # Unblock reverse lookups for LAN addresses
  63. unblock-lan-zones: yes
  64. insecure-lan-zones: yes
  65. ## Datei /var/unbound/conf.d/zone.conf
  66. auth-zone:
  67. name: ffdo.net
  68. master: 193.43.220.129
  69. zonefile: /var/unbound/zone/ffdo.net
  70. auth-zone:
  71. name: 220.43.193.in-addr.arpa
  72. master: 193.43.220.129
  73. zonefile: /var/unbound/zone/220.43.193.in-addr.arpa
  74. auth-zone:
  75. name: 221.43.193.in-addr.arpa
  76. master: 193.43.220.129
  77. zonefile: /var/unbound/zone/221.43.193.in-addr.arpa
  78. # Hoerde
  79. ## Datei /var/unbound/unbound.conf
  80. # This file was generated by local-unbound-setup.
  81. # Modifications will be overwritten.
  82. server:
  83. username: unbound
  84. directory: /var/unbound
  85. chroot: /var/unbound
  86. pidfile: /var/run/local_unbound.pid
  87. use-syslog: yes
  88. auto-trust-anchor-file: /var/unbound/root.key
  89. interface: 127.0.0.1
  90. interface: ::1
  91. interface: 193.43.220.136
  92. interface: 193.43.220.168
  93. access-control: 127.0.0.1/32 allow
  94. access-control: ::1 allow
  95. access-control: 193.43.220.0/23 allow
  96. access-control: 91.204.4.0/22 allow
  97. access-control: 192.168.0.0/16 allow
  98. access-control: 0.0.0.0/0 refuse_non_local
  99. #val-permissive-mode: "yes"
  100. ## Datei /var/unbound/conf.d/control.conf
  101. # This file was generated by local-unbound-setup.
  102. # Modifications will be overwritten.
  103. remote-control:
  104. control-enable: yes
  105. control-interface: /var/run/local_unbound.ctl
  106. control-use-cert: no
  107. ## Datei /var/unbound/conf.d/forward.conf
  108. forward-zone:
  109. name: "."
  110. forward-addr: 193.43.220.129
  111. forward-first: yes
  112. ## Datei /var/unbound/conf.d/lan-zones.conf
  113. # This file was generated by local-unbound-setup.
  114. # Modifications will be overwritten.
  115. server:
  116. # Unblock reverse lookups for LAN addresses
  117. unblock-lan-zones: yes
  118. insecure-lan-zones: yes
  119. ## Datei /var/unbound/conf.d/zone.conf
  120. auth-zone:
  121. name: ffdo.net
  122. master: 193.43.220.129
  123. zonefile: /var/unbound/zone/ffdo.net
  124. auth-zone:
  125. name: 220.43.193.in-addr.arpa
  126. master: 193.43.220.129
  127. zonefile: /var/unbound/zone/220.43.193.in-addr.arpa
  128. auth-zone:
  129. name: 221.43.193.in-addr.arpa
  130. master: 193.43.220.129
  131. zonefile: /var/unbound/zone/221.43.193.in-addr.arpa