This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
computing:unbounddns [2024/11/01 04:21] – oemb1905 | computing:unbounddns [2025/05/04 06:01] (current) – oemb1905 | ||
---|---|---|---|
Line 78: | Line 78: | ||
<if $programname == ' | <if $programname == ' | ||
<& stop> | <& stop> | ||
+ | nano / | ||
+ | | ||
+ | In the log rotate file, enter the following: | ||
+ | |||
+ | / | ||
+ | daily | ||
+ | rotate 7 | ||
+ | missingok | ||
+ | create 0640 root adm | ||
+ | postrotate | ||
+ | / | ||
+ | endscript | ||
+ | } | ||
Additionally, | Additionally, | ||
Line 100: | Line 113: | ||
< | < | ||
+ | The last step is configuring the unbound server in the pihole GUI. Alternately, | ||
+ | |||
+ | server: | ||
+ | interface: 127.0.0.1 | ||
+ | cache-max-ttl: | ||
+ | cache-min-ttl: | ||
+ | num-threads: | ||
+ | msg-cache-slabs: | ||
+ | rrset-cache-slabs: | ||
+ | infra-cache-slabs: | ||
+ | key-cache-slabs: | ||
+ | rrset-cache-size: | ||
+ | msg-cache-size: | ||
+ | #prefetch: yes | ||
+ | harden-dnssec-stripped: | ||
+ | use-syslog: yes | ||
+ | aggressive-nsec: | ||
+ | hide-identity: | ||
+ | hide-version: | ||
+ | use-caps-for-id: | ||
+ | do-tcp: yes | ||
+ | do-udp: yes | ||
+ | |||
+ | Then, just add '' | ||
+ | |||
+ | include-toplevel: | ||
+ | server: | ||
+ | # Bind to localhost only | ||
+ | interface: 127.0.0.1 | ||
+ | interface: ::1 | ||
+ | port: 53 | ||
+ | do-ip4: yes | ||
+ | do-ip6: yes | ||
+ | prefer-ip6: yes | ||
+ | access-control: | ||
+ | access-control: | ||
+ | access-control: | ||
+ | # Optimize for 8 cores | ||
+ | num-threads: | ||
+ | msg-cache-slabs: | ||
+ | rrset-cache-slabs: | ||
+ | infra-cache-slabs: | ||
+ | key-cache-slabs: | ||
+ | # Cache settings for high query volume | ||
+ | cache-max-ttl: | ||
+ | cache-min-ttl: | ||
+ | rrset-cache-size: | ||
+ | msg-cache-size: | ||
+ | key-cache-size: | ||
+ | neg-cache-size: | ||
+ | # Enable prefetch and expired responses | ||
+ | prefetch: yes | ||
+ | prefetch-key: | ||
+ | serve-expired: | ||
+ | serve-expired-ttl: | ||
+ | # DNSSEC validation for DANE | ||
+ | #do-dnssec: yes | ||
+ | harden-dnssec-stripped: | ||
+ | harden-referral-path: | ||
+ | harden-below-nxdomain: | ||
+ | harden-algo-downgrade: | ||
+ | # Performance tweaks | ||
+ | #so-rcvbuf: 4m | ||
+ | #so-sndbuf: 4m | ||
+ | edns-buffer-size: | ||
+ | outgoing-range: | ||
+ | num-queries-per-thread: | ||
+ | jostle-timeout: | ||
+ | # | ||
+ | # Logging (minimal) | ||
+ | verbosity: 1 | ||
+ | log-queries: | ||
+ | log-replies: | ||
+ | use-syslog: yes | ||
+ | # Security and privacy | ||
+ | hide-identity: | ||
+ | hide-version: | ||
+ | use-caps-for-id: | ||
+ | qname-minimisation: | ||
+ | harden-large-queries: | ||
+ | harden-glue: | ||
+ | aggressive-nsec: | ||
+ | # Protocol settings | ||
+ | do-tcp: yes | ||
+ | do-udp: yes | ||
+ | # Enable full recursion - no longer needed, retained for history | ||
+ | # do-not-query-localhost: | ||
+ | # root-hints: "/ | ||
+ | # Disable subnetcache | ||
+ | module-config: | ||
+ | # Forward to upstream resolvers | ||
+ | # forward-zone: | ||
+ | # name: " | ||
+ | # forward-addr: | ||
+ | # forward-addr: | ||
+ | #legacy | ||
+ | #server: | ||
+ | # interface: 127.0.0.1 | ||
+ | # cache-max-ttl: | ||
+ | # cache-min-ttl: | ||
+ | # num-threads: | ||
+ | # msg-cache-slabs: | ||
+ | # rrset-cache-slabs: | ||
+ | # infra-cache-slabs: | ||
+ | # key-cache-slabs: | ||
+ | # rrset-cache-size: | ||
+ | # msg-cache-size: | ||
+ | # #prefetch: yes | ||
+ | # harden-dnssec-stripped: | ||
+ | # use-syslog: yes | ||
+ | # aggressive-nsec: | ||
+ | # hide-identity: | ||
+ | # hide-version: | ||
+ | # use-caps-for-id: | ||
+ | # do-tcp: yes | ||
+ | # do-udp: yes | ||
+ | # do-ip4: yes | ||
+ | # do-ip6: yes | ||
+ | # prefer-ip6: no | ||
+ | | ||
+ | And now, the current lan-based config, in '' | ||
+ | server: | ||
+ | # Logging (minimal) | ||
+ | use-syslog: yes | ||
+ | verbosity: 1 | ||
+ | directory: "/ | ||
+ | username: unbound | ||
+ | # Bind to all interfaces, non-standard port | ||
+ | interface: 0.0.0.0 | ||
+ | interface: ::0 | ||
+ | port: 5335 | ||
+ | do-ip4: yes | ||
+ | do-ip6: yes | ||
+ | prefer-ip6: no | ||
+ | do-udp: yes | ||
+ | do-tcp: yes | ||
+ | # Module configuration | ||
+ | module-config: | ||
+ | # Security and DNSSEC | ||
+ | harden-glue: | ||
+ | harden-dnssec-stripped: | ||
+ | use-caps-for-id: | ||
+ | aggressive-nsec: | ||
+ | hide-identity: | ||
+ | hide-version: | ||
+ | qname-minimisation: | ||
+ | harden-large-queries: | ||
+ | # Cache settings | ||
+ | cache-max-ttl: | ||
+ | cache-min-ttl: | ||
+ | rrset-cache-size: | ||
+ | msg-cache-size: | ||
+ | key-cache-size: | ||
+ | neg-cache-size: | ||
+ | # Performance tweaks | ||
+ | num-threads: | ||
+ | msg-cache-slabs: | ||
+ | rrset-cache-slabs: | ||
+ | infra-cache-slabs: | ||
+ | key-cache-slabs: | ||
+ | outgoing-range: | ||
+ | num-queries-per-thread: | ||
+ | infra-cache-numhosts: | ||
+ | prefetch: yes | ||
+ | prefetch-key: | ||
+ | serve-expired: | ||
+ | serve-expired-ttl: | ||
+ | so-reuseport: | ||
+ | edns-buffer-size: | ||
+ | # Block private address ranges (excluding own subnets) | ||
+ | private-address: | ||
+ | private-address: | ||
+ | private-address: | ||
+ | private-address: | ||
+ | private-address: | ||
+ | # Access control for LAN and VPN subnets | ||
+ | access-control: | ||
+ | access-control: | ||
+ | access-control: | ||
+ | access-control: | ||
- | --- //[[webmaster@haacksnetworking.org|oemb1905]] | + | --- //[[alerts@haacksnetworking.org|oemb1905]] |