]> git.ipfire.org Git - thirdparty/pdns.git/blob - docs/settings.rst
Merge pull request #7677 from rgacogne/dnsdist-logging-facility
[thirdparty/pdns.git] / docs / settings.rst
1 Authoritative Server Settings
2 =============================
3
4 All PowerDNS Authoritative Server settings are listed here, excluding
5 those that originate from backends, which are documented in the relevant
6 chapters. These settings can be set inside ``pdns.conf`` or on the
7 commandline when invoking the ``pdns`` binary.
8
9 You can use ``+=`` syntax to set some variables incrementally, but this
10 requires you to have at least one non-incremental setting for the
11 variable to act as base setting. This is mostly useful for
12 :ref:`setting-include-dir` directive.
13
14 For boolean settings, specifying the name of the setting without a value
15 means ``yes``.
16
17 .. _setting-8bit-dns:
18
19 ``8bit-dns``
20 ------------
21
22 - Allow 8 bit dns queries
23 - Default: no
24
25 .. versionadded:: 4.0.0
26
27 Allow 8 bit DNS queries.
28
29 .. _setting-allow-axfr-ips:
30
31 ``allow-axfr-ips``
32 ------------------
33
34 - IP ranges, separated by commas
35 - Default: 127.0.0.0/8,::1
36
37 If set, only these IP addresses or netmasks will be able to perform
38 AXFR.
39
40 .. _setting-allow-dnsupdate-from:
41
42 ``allow-dnsupdate-from``
43 ------------------------
44
45 - IP ranges, separated by commas
46 - Default: 127.0.0.0/8,::1
47
48 Allow DNS updates from these IP ranges. Set to empty string to honour ``ALLOW-DNSUPDATE-FROM`` in :ref:`metadata-allow-dnsupdate-from`.
49
50 .. _setting-allow-notify-from:
51
52 ``allow-notify-from``
53 ---------------------
54
55 - IP ranges, separated by commas
56 - Default: 0.0.0.0/0,::/0
57
58 Allow AXFR NOTIFY from these IP ranges. Setting this to an empty string
59 will drop all incoming notifies.
60
61 .. _setting-allow-unsigned-notify:
62
63 ``allow-unsigned-notify``
64 -------------------------
65
66 - Boolean
67 - Default: yes
68
69 .. versionadded:: 4.0.0
70
71 Turning this off requires all notifications that are received to be
72 signed by valid TSIG signature for the zone.
73
74 .. _setting-allow-unsigned-supermaster:
75
76 ``allow-unsigned-supermaster``
77 ------------------------------
78
79 - Boolean
80 - Default: yes
81
82 .. versionadded:: 4.0.0
83
84 Turning this off requires all supermaster notifications to be signed by
85 valid TSIG signature. It will accept any existing key on slave.
86
87 .. _setting-allow-recursion:
88
89 ``allow-recursion``
90 -------------------
91
92 - IP ranges, separated by commas
93 - Default: 0.0.0.0/0
94
95 .. deprecated:: 4.1.0
96 Recursion has been removed, see :doc:`guides/recursion`
97
98 By specifying ``allow-recursion``, recursion can be restricted to
99 netmasks specified. The default is to allow recursion from everywhere.
100 Example: ``allow-recursion=198.51.100.0/24, 10.0.0.0/8, 192.0.2.4``.
101
102 .. _setting-also-notify:
103
104 ``also-notify``
105 ---------------
106
107 - IP addresses, separated by commas
108
109 When notifying a domain, also notify these nameservers. Example:
110 ``also-notify=192.0.2.1, 203.0.113.167``. The IP addresses listed in
111 ``also-notify`` always receive a notification. Even if they do not match
112 the list in :ref:`setting-only-notify`.
113
114 .. _setting-any-to-tcp:
115
116 ``any-to-tcp``
117 --------------
118
119 - Boolean
120 - Default: yes
121
122 .. versionchanged:: 4.0.1, was 'no' before.
123
124 Answer questions for the ANY on UDP with a truncated packet that refers
125 the remote server to TCP. Useful for mitigating reflection attacks.
126
127 .. _setting-api:
128
129 ``api``
130 -------
131
132 - Boolean
133 - Default: no
134
135 Enable/disable the :doc:`http-api/index`.
136
137 .. _setting-api-key:
138
139 ``api-key``
140 -----------
141
142 - String
143
144 .. versionadded:: 4.0.0
145
146 Static pre-shared authentication key for access to the REST API.
147
148 .. _setting-api-readonly:
149
150 ``api-readonly``
151 ----------------
152
153 - Boolean
154 - Default: no
155
156 .. versionadded:: 4.0.0
157 .. versionchanged:: 4.2.0
158 This setting has been removed in 4.2.0.
159
160 Disallow data modification through the REST API when set.
161
162 .. _setting-axfr-lower-serial:
163
164 ``axfr-lower-serial``
165 ---------------------
166
167 - Boolean
168 - Default: no
169
170 .. versionadded:: 4.0.4
171
172 Also AXFR a zone from a master with a lower serial.
173
174 .. _setting-cache-ttl:
175
176 ``cache-ttl``
177 -------------
178
179 - Integer
180 - Default: 20
181
182 Seconds to store packets in the :ref:`packet-cache`.
183
184 .. _setting-carbon-namespace:
185
186 ``carbon-namespace``
187 --------------------
188
189 - String
190 - Default: pdns
191
192 .. versionadded:: 4.2.0
193
194 Set the namespace or first string of the metric key. Be careful not to include
195 any dots in this setting, unless you know what you are doing.
196 See :ref:`metricscarbon`
197
198 .. _setting-carbon-ourname:
199
200 ``carbon-ourname``
201 ------------------
202
203 - String
204 - Default: the hostname of the server
205
206 If sending carbon updates, if set, this will override our hostname. Be
207 careful not to include any dots in this setting, unless you know what
208 you are doing. See :ref:`metricscarbon`
209
210 .. _setting-carbon-instance:
211
212 ``carbon-instance``
213 -------------------
214
215 - String
216 - Default: auth
217
218 .. versionadded:: 4.2.0
219
220 Set the instance or third string of the metric key. Be careful not to include
221 any dots in this setting, unless you know what you are doing.
222 See :ref:`metricscarbon`
223
224 .. _setting-carbon-server:
225
226 ``carbon-server``
227 -----------------
228
229 - IP Address
230
231 Send all available metrics to this server via the carbon protocol, which
232 is used by graphite and metronome. It has to be an address (no
233 hostnames). Moreover you can specify more than one server using a comma delimited list, ex:
234 carbon-server=10.10.10.10,10.10.10.20.
235 You may specify an alternate port by appending :port, ex:
236 127.0.0.1:2004. See :ref:`metricscarbon`.
237
238 .. _setting-carbon-interval:
239
240 ``carbon-interval``
241 -------------------
242
243 - Integer
244 - Default: 30
245
246 If sending carbon updates, this is the interval between them in seconds.
247 See :ref:`metricscarbon`.
248
249 .. _setting-chroot:
250
251 ``chroot``
252 ----------
253
254 - Path
255
256 If set, chroot to this directory for more security. See :doc:`security`.
257
258 Make sure that ``/dev/log`` is available from within the chroot. Logging
259 will silently fail over time otherwise (on logrotate).
260
261 When setting ``chroot``, all other paths in the config (except for
262 :ref:`setting-config-dir` and :ref:`setting-module-dir`)
263 set in the configuration are relative to the new root.
264
265 When running on a system where systemd manages services, ``chroot`` does
266 not work out of the box, as PowerDNS cannot use the ``NOTIFY_SOCKET``.
267 Either don't ``chroot`` on these systems or set the 'Type' of the this
268 service to 'simple' instead of 'notify' (refer to the systemd
269 documentation on how to modify unit-files)
270
271 .. _setting-config-dir:
272
273 ``config-dir``
274 --------------
275
276 - Path
277
278 Location of configuration directory (``pdns.conf``). Usually
279 ``/etc/powerdns``, but this depends on ``SYSCONFDIR`` during
280 compile-time.
281
282 .. _setting-config-name:
283
284 ``config-name``
285 ---------------
286
287 - String
288
289 Name of this virtual configuration - will rename the binary image. See
290 :doc:`guides/virtual-instances`.
291
292 .. _setting-control-console:
293
294 ``control-console``
295 -------------------
296
297 Debugging switch - don't use.
298
299 .. _setting-daemon:
300
301 ``daemon``
302 ----------
303
304 - Boolean
305 - Default: no
306
307 Operate as a daemon.
308
309 .. _setting-default-api-rectify:
310
311 ``default-api-rectify``
312 -----------------------
313 - Boolean
314 - Default: yes
315
316 .. versionadded:: 4.2.0
317
318 The value of :ref:`metadata-api-rectify` if it is not set on the zone.
319
320 .. note::
321 Pre 4.2.0 the default was always no.
322
323 .. _setting-default-ksk-algorithms:
324 .. _setting-default-ksk-algorithm:
325
326 ``default-ksk-algorithm``
327 --------------------------
328
329 - String
330 - Default: ecdsa256
331
332 .. versionchanged:: 4.1.0
333 Renamed from ``default-ksk-algorithms``. No longer supports multiple algorithm names.
334
335 The algorithm that should be used for the KSK when running
336 :doc:`pdnsutil secure-zone <manpages/pdnsutil.1>` or using the :doc:`Zone API endpoint <http-api/cryptokey>`
337 to enable DNSSEC. Must be one of:
338
339 * rsasha1
340 * rsasha256
341 * rsasha512
342 * ecdsa256 (ECDSA P-256 with SHA256)
343 * ecdsa384 (ECDSA P-384 with SHA384)
344 * ed25519
345 * ed448
346
347 .. note::
348 Actual supported algorithms depend on the crypto-libraries
349 PowerDNS was compiled against. To check the supported DNSSEC algoritms
350 in your build of PowerDNS, run ``pdnsutil list-algorithms``.
351
352 .. _setting-default-ksk-size:
353
354 ``default-ksk-size``
355 --------------------
356
357 - Integer
358 - Default: whichever is default for `default-ksk-algorithm`_
359
360 The default keysize for the KSK generated with :doc:`pdnsutil secure-zone <dnssec/pdnsutil>`.
361 Only relevant for algorithms with non-fixed keysizes (like RSA).
362
363 .. _setting-default-soa-name:
364
365 ``default-soa-name``
366 --------------------
367
368 - String
369 - Default: a.misconfigured.powerdns.server
370
371 Name to insert in the SOA record if none set in the backend.
372
373 .. _setting-default-soa-edit:
374
375 ``default-soa-edit``
376 --------------------
377
378 - String
379 - Default: empty
380
381 Use this soa-edit value for all zones if no
382 :ref:`metadata-soa-edit` metadata value is set.
383
384 .. _setting-default-soa-edit-signed:
385
386 ``default-soa-edit-signed``
387 ---------------------------
388
389 - String
390 - Default: empty
391
392 Use this soa-edit value for all signed zones if no
393 :ref:`metadata-soa-edit` metadata value is set.
394 Overrides :ref:`setting-default-soa-edit`
395
396 .. _setting-default-soa-mail:
397
398 ``default-soa-mail``
399 --------------------
400
401 - String
402
403 Mail address to insert in the SOA record if none set in the backend.
404
405 .. _setting-default-ttl:
406
407 ``default-ttl``
408 ---------------
409
410 - Integer
411 - Default: 3600
412
413 TTL to use when none is provided.
414
415 .. _setting-default-zsk-algorithms:
416 .. _setting-default-zsk-algorithm:
417
418 ``default-zsk-algorithm``
419 --------------------------
420
421 - String
422 - Default: (empty)
423
424 .. versionchanged:: 4.1.0
425 Renamed from ``default-zsk-algorithms``. Does no longer support multiple algorithm names.
426
427 The algorithm that should be used for the ZSK when running
428 :doc:`pdnsutil secure-zone <manpages/pdnsutil.1>` or using the :doc:`Zone API endpoint <http-api/cryptokey>`
429 to enable DNSSEC. Must be one of:
430
431 * rsasha1
432 * rsasha256
433 * rsasha512
434 * ecdsa256 (ECDSA P-256 with SHA256)
435 * ecdsa384 (ECDSA P-384 with SHA384)
436 * ed25519
437 * ed448
438
439 .. note::
440 Actual supported algorithms depend on the crypto-libraries
441 PowerDNS was compiled against. To check the supported DNSSEC algoritms
442 in your build of PowerDNS, run ``pdnsutil list-algorithms``.
443
444 .. _setting-default-zsk-size:
445
446 ``default-zsk-size``
447 --------------------
448
449 - Integer
450 - Default: 0 (automatic default for `default-zsk-algorithm`_)
451
452 The default keysize for the ZSK generated with :doc:`pdnsutil secure-zone <dnssec/pdnsutil>`.
453 Only relevant for algorithms with non-fixed keysizes (like RSA).
454
455 .. _setting-direct-dnskey:
456
457 ``direct-dnskey``
458 -----------------
459
460 - Boolean
461 - Default: no
462
463 Read additional DNSKEY, CDS and CDNSKEY records from the records table/your BIND zonefile. If not
464 set, DNSKEY, CDS and CDNSKEY records in the zonefiles are ignored.
465
466 .. _setting-disable-axfr:
467
468 ``disable-axfr``
469 ----------------
470
471 - Boolean
472 - Default: no
473
474 Do not allow zone transfers.
475
476 .. _setting-disable-axfr-rectify:
477
478 ``disable-axfr-rectify``
479 ------------------------
480
481 - Boolean
482 - Default: no
483
484 Disable the rectify step during an outgoing AXFR. Only required for
485 regression testing.
486
487 .. _setting-disable-syslog:
488
489 ``disable-syslog``
490 ------------------
491
492 - Boolean
493 - Default: no
494
495 Do not log to syslog, only to stdout. Use this setting when running
496 inside a supervisor that handles logging (like systemd).
497
498 .. warning::
499 Do not use this setting in combination with :ref:`setting-daemon` as all
500 logging will disappear.
501
502 .. _setting-disable-tcp:
503
504 ``disable-tcp``
505 ---------------
506
507 - Boolean
508 - Default: no
509
510 Do not listen to TCP queries. Breaks RFC compliance.
511
512 .. _setting-distributor-threads:
513
514 ``distributor-threads``
515 -----------------------
516
517 - Integer
518 - Default: 3
519
520 Number of Distributor (backend) threads to start per receiver thread.
521 See :doc:`performance`.
522
523 .. _setting-dname-processing:
524
525 ``dname-processing``
526 --------------------
527
528 - Boolean
529 - Default: no
530
531 Synthesise CNAME records from DNAME records as required. This
532 approximately doubles query load. **Do not combine with DNSSEC!**
533
534 .. _setting-dnssec-key-cache-ttl:
535
536 ``dnssec-key-cache-ttl``
537 ------------------------
538
539 - Integer
540 - Default: 30
541
542 Seconds to cache DNSSEC keys from the database. A value of 0 disables
543 caching.
544
545 .. _setting-dnsupdate:
546
547 ``dnsupdate``
548 -------------
549
550 - Boolean
551 - Default: no
552
553 Enable/Disable DNS update (RFC2136) support. See :doc:`dnsupdate` for more.
554
555 .. _setting-do-ipv6-additional-processing:
556
557 ``do-ipv6-additional-processing``
558 ---------------------------------
559
560 - Boolean
561 - Default: yes
562
563 Perform AAAA additional processing. This sends AAAA records in the
564 ADDITIONAL section when sending a referral.
565
566 .. _setting-domain-metadata-cache-ttl:
567
568 ``domain-metadata-cache-ttl``
569 -----------------------------
570
571 - Integer
572 - Default: 60
573
574 Seconds to cache domain metadata from the database. A value of 0
575 disables caching.
576
577 .. _setting-edns-subnet-processing:
578
579 ``edns-subnet-processing``
580 --------------------------
581
582 - Boolean
583 - Default: no
584
585 Enables EDNS subnet processing, for backends that support it.
586
587 .. _setting-enable-lua-records:
588
589 ``enable-lua-records``
590 ----------------------
591
592 - Boolean
593 - Default: no
594
595 Enable globally the LUA records feature
596
597 .. _setting-entropy-source:
598
599 ``entropy-source``
600 ------------------
601
602 - Path
603 - Default: /dev/urandom
604
605 Entropy source file to use.
606
607 .. _setting-expand-alias:
608
609 ``expand-alias``
610 ----------------
611
612 - Boolean
613 - Default: no
614
615 .. versionadded:: 4.1.0
616
617 If this is enabled, ALIAS records are expanded (synthesised to their
618 A/AAAA).
619
620 If this is disabled (the default), ALIAS records will not expanded and
621 the server will will return NODATA for A/AAAA queries for such names.
622
623 **note**: :ref:`setting-resolver` must also be set for ALIAS
624 expansion to work!
625
626 **note**: In PowerDNS Authoritative Server 4.0.x, this setting did not
627 exist and ALIAS was always expanded.
628
629 .. _setting-forward-dnsupdate:
630
631 ``forward-dnsupdate``
632 ---------------------
633
634 - Boolean
635 - Default: no
636
637 Forward DNS updates sent to a slave to the master.
638
639 .. _setting-forward-notify:
640
641 ``forward-notify``
642 ------------------
643
644 - IP addresses, separated by commas
645
646 IP addresses to forward received notifications to regardless of master
647 or slave settings.
648
649 .. note::
650 The intended use is in anycast environments where it might be
651 necessary for a proxy server to perform the AXFR. The usual checks are
652 performed before any received notification is forwarded.
653
654 .. _setting-guardian:
655
656 ``guardian``
657 ------------
658
659 - Boolean
660 - Default: no
661
662 Run within a guardian process. See :ref:`running-guardian`.
663
664 .. _setting-include-dir:
665
666 ``include-dir``
667 ---------------
668
669 - Path
670
671 Directory to scan for additional config files. All files that end with
672 .conf are loaded in order using ``POSIX`` as locale.
673
674 .. _setting-launch:
675
676 ``launch``
677 ----------
678
679 - Backend names, separated by commas
680
681 Which backends to launch and order to query them in. Launches backends.
682 In its most simple form, supply all backends that need to be launched.
683 e.g.
684
685 ::
686
687 launch=bind,gmysql,remote
688
689 If you find that you need to query a backend multiple times with
690 different configuration, you can specify a name for later
691 instantiations. e.g.:
692
693 ::
694
695 launch=gmysql,gmysql:server2
696
697 In this case, there are 2 instances of the gmysql backend, one by the
698 normal name and the second one is called 'server2'. The backend
699 configuration item names change: e.g. ``gmysql-host`` is available to
700 configure the ``host`` setting of the first or main instance, and
701 ``gmysql-server2-host`` for the second one.
702
703 Running multiple instances of the bind backend is not allowed.
704
705 .. _setting-load-modules:
706
707 ``load-modules``
708 ----------------
709
710 - Paths, separated by commas
711
712 If backends are available in nonstandard directories, specify their
713 location here. Multiple files can be loaded if separated by commas. Only
714 available in non-static distributions.
715
716 .. _setting-local-address:
717
718 ``local-address``
719 -----------------
720
721 - IPv4 Addresses, separated by commas or whitespace
722 - Default: 0.0.0.0
723
724 Local IP address to which we bind. It is highly advised to bind to
725 specific interfaces and not use the default 'bind to any'. This causes
726 big problems if you have multiple IP addresses. Unix does not provide a
727 way of figuring out what IP address a packet was sent to when binding to
728 any.
729
730 .. _setting-log-timestamp:
731
732 ``log-timestamp``
733 -----------------
734
735 .. versionadded:: 4.1.0
736
737 - Bool
738 - Default: yes
739
740 When printing log lines to stdout, prefix them with timestamps.
741 Disable this if the process supervisor timestamps these lines already.
742
743 .. note::
744 The systemd unit file supplied with the source code already disables timestamp printing
745
746 .. _setting-lua-records-exec-limit:
747
748 ``lua-records-exec-limit``
749 -----------------------------
750
751 - Integer
752 - Default: 1000
753
754 Limit LUA records scripts to ``lua-records-exec-limit`` instructions.
755 Setting this to any value less than or equal to 0 will set no limit.
756
757 .. _setting-non-local-bind:
758
759 ``non-local-bind``
760 ------------------
761
762 - Boolean
763 - Default: no
764
765 Bind to addresses even if one or more of the
766 :ref:`setting-local-address`'s do not exist on this server.
767 Setting this option will enable the needed socket options to allow
768 binding to non-local addresses. This feature is intended to facilitate
769 ip-failover setups, but it may also mask configuration issues and for
770 this reason it is disabled by default.
771
772 .. _setting-lua-axfr-script:
773
774 ``lua-axfr-script``
775 -------------------
776
777 - String
778 - Default: empty
779
780 .. versionadded:: 4.1.0
781
782 Script to be used to edit incoming AXFRs, see :ref:`modes-of-operation-axfrfilter`
783
784 .. _setting-local-address-nonexist-fail:
785
786 ``local-address-nonexist-fail``
787 -------------------------------
788
789 - Boolean
790 - Default: no
791
792 Fail to start if one or more of the
793 :ref:`setting-local-address`'s do not exist on this server.
794
795 .. _setting-local-ipv6:
796
797 ``local-ipv6``
798 --------------
799
800 - IPv6 Addresses, separated by commas or whitespace
801 - Default: '::'
802
803 Local IPv6 address to which we bind. It is highly advised to bind to
804 specific interfaces and not use the default 'bind to any'. This causes
805 big problems if you have multiple IP addresses.
806
807 .. _setting-local-ipv6-nonexist-fail:
808
809 ``local-ipv6-nonexist-fail``
810 ----------------------------
811
812 - Boolean
813 - Default: no
814
815 Fail to start if one or more of the :ref:`setting-local-ipv6`
816 addresses do not exist on this server.
817
818 .. _setting-local-port:
819
820 ``local-port``
821 --------------
822
823 - Integer
824 - Default: 53
825
826 The port on which we listen. Only one port possible.
827
828 .. _setting-log-dns-details:
829
830 ``log-dns-details``
831 -------------------
832
833 - Boolean
834 - Default: no
835
836 If set to 'no', informative-only DNS details will not even be sent to
837 syslog, improving performance.
838
839 .. _setting-logging-facility:
840
841 ``logging-facility``
842 --------------------
843
844 If set to a digit, logging is performed under this LOCAL facility. See :ref:`logging-to-syslog`.
845 Do not pass names like 'local0'!
846
847 .. _setting-loglevel:
848
849 ``loglevel``
850 ------------
851
852 - Integer
853 - Default: 4
854
855 Amount of logging. Higher is more. Do not set below 3. Corresponds to "syslog" level values,
856 e.g. error = 3, warning = 4, notice = 5, info = 6
857
858 .. _setting-log-dns-queries:
859
860 ``log-dns-queries``
861 -------------------
862
863 - Boolean
864 - Default: no
865
866 Tell PowerDNS to log all incoming DNS queries. This will lead to a lot
867 of logging! Only enable for debugging! Set :ref:`setting-loglevel`
868 to at least 5 to see the logs.
869
870 .. _setting-lua-prequery-script:
871
872 ``lua-prequery-script``
873 -----------------------
874
875 - Path
876
877 Lua script to run before answering a query. This is a feature used
878 internally for regression testing. The API of this functionality is not
879 guaranteed to be stable, and is in fact likely to change.
880
881 .. _setting-master:
882
883 ``master``
884 ----------
885
886 - Boolean
887 - Default: no
888
889 Turn on master support. See :ref:`master-operation`.
890
891 .. _setting-max-cache-entries:
892
893 ``max-cache-entries``
894 ---------------------
895
896 - Integer
897 - Default: 1000000
898
899 .. versionchanged:: 4.1.0
900 The packet and query caches are distinct. Previously, this setting was used for
901 both the packet and query caches. See ref:`setting-max-packet-cache-entries` for
902 the packet-cache setting.
903
904 Maximum number of entries in the query cache. 1 million (the default)
905 will generally suffice for most installations.
906
907 .. _setting-max-ent-entries:
908
909 ``max-ent-entries``
910 -------------------
911
912 - Integer
913 - Default: 100000
914
915 Maximum number of empty non-terminals to add to a zone. This is a
916 protection measure to avoid database explosion due to long names.
917
918 .. _setting-max-nsec3-iterations:
919
920 ``max-nsec3-iterations``
921 ------------------------
922
923 - Integer
924 - Default: 500
925
926 Limit the number of NSEC3 hash iterations
927
928 .. _setting-max-packet-cache-entries:
929
930 ``max-packet-cache-entries``
931 ----------------------------
932
933 - Integer
934 - Default: 1000000
935
936 .. versionadded:: 4.1.0
937
938 Maximum number of entries in the packet cache. 1 million (the default)
939 will generally suffice for most installations.
940
941 .. _setting-max-queue-length:
942
943 ``max-queue-length``
944 --------------------
945
946 - Integer
947 - Default: 5000
948
949 If this many packets are waiting for database attention, consider the
950 situation hopeless and respawn.
951
952 .. _setting-max-signature-cache-entries:
953
954 ``max-signature-cache-entries``
955 -------------------------------
956
957 - Integer
958 - Default: 2^31-1 (on most systems), 2^63-1 (on ILP64 systems)
959
960 Maximum number of signatures cache entries
961
962 .. _setting-max-tcp-connection-duration:
963
964 ``max-tcp-connection-duration``
965 -------------------------------
966
967 - Integer
968 - Default: 0
969
970 Maximum time in seconds that a TCP DNS connection is allowed to stay
971 open. 0 means unlimited. Note that exchanges related to an AXFR or IXFR
972 are not affected by this setting.
973
974 .. _setting-max-tcp-connections:
975
976 ``max-tcp-connections``
977 -----------------------
978
979 - Integer
980 - Default: 20
981
982 Allow this many incoming TCP DNS connections simultaneously.
983
984 .. _setting-max-tcp-connections-per-client:
985
986 ``max-tcp-connections-per-client``
987 ----------------------------------
988
989 - Integer
990 - Default: 0
991
992 Maximum number of simultaneous TCP connections per client. 0 means
993 unlimited.
994
995 .. _setting-max-tcp-transactions-per-conn:
996
997 ``max-tcp-transactions-per-conn``
998 ---------------------------------
999
1000 - Integer
1001 - Default: 0
1002
1003 Allow this many DNS queries in a single TCP transaction. 0 means
1004 unlimited. Note that exchanges related to an AXFR or IXFR are not
1005 affected by this setting.
1006
1007 .. _setting-module-dir:
1008
1009 ``module-dir``
1010 --------------
1011
1012 - Path
1013
1014 Directory for modules. Default depends on ``PKGLIBDIR`` during
1015 compile-time.
1016
1017 .. _setting-negquery-cache-ttl:
1018
1019 ``negquery-cache-ttl``
1020 ----------------------
1021
1022 - Integer
1023 - Default: 60
1024
1025 Seconds to store queries with no answer in the Query Cache. See ref:`query-cache`.
1026
1027 .. _setting-no-config:
1028
1029 ``no-config``
1030 -------------
1031
1032 - Boolean
1033 - Default: no
1034
1035 Do not attempt to read the configuration file.
1036
1037 .. _setting-no-shuffle:
1038
1039 ``no-shuffle``
1040 --------------
1041
1042 - Boolean
1043 - Default: no
1044
1045 Do not attempt to shuffle query results, used for regression testing.
1046
1047 .. _setting-overload-queue-length:
1048
1049 ``overload-queue-length``
1050 -------------------------
1051
1052 - Integer
1053 - Default: 0 (disabled)
1054
1055 If this many packets are waiting for database attention, answer any new
1056 questions strictly from the packet cache.
1057
1058 .. _setting-reuseport:
1059
1060 ``reuseport``
1061 -------------
1062
1063 - Boolean
1064 - Default: No
1065
1066 On Linux 3.9 and some BSD kernels the ``SO_REUSEPORT`` option allows
1067 each receiver-thread to open a new socket on the same port which allows
1068 for much higher performance on multi-core boxes. Setting this option
1069 will enable use of ``SO_REUSEPORT`` when available and seamlessly fall
1070 back to a single socket when it is not available. A side-effect is that
1071 you can start multiple servers on the same IP/port combination which may
1072 or may not be a good idea. You could use this to enable transparent
1073 restarts, but it may also mask configuration issues and for this reason
1074 it is disabled by default.
1075
1076 .. _setting-rng:
1077
1078 ``rng``
1079 -------
1080
1081 - String
1082 - Default: auto
1083
1084 Specify which random number generator to use. Permissible choises are
1085 - auto - choose automatically
1086 - sodium - Use libsodium ``randombytes_uniform``
1087 - openssl - Use libcrypto ``RAND_bytes``
1088 - getrandom - Use libc getrandom, falls back to urandom if it does not really work
1089 - arc4random - Use BSD ``arc4random_uniform``
1090 - urandom - Use ``/dev/urandom``
1091 - kiss - Use simple settable deterministic RNG. **FOR TESTING PURPOSES ONLY!**
1092
1093 .. note::
1094 Not all choises are available on all systems.
1095
1096 .. _setting-security-poll-suffix:
1097
1098 ``security-poll-suffix``
1099 ------------------------
1100
1101 - String
1102 - Default: secpoll.powerdns.com.
1103
1104 Domain name from which to query security update notifications. Setting
1105 this to an empty string disables secpoll.
1106
1107 .. _setting-server-id:
1108
1109 ``server-id``
1110 -------------
1111
1112 - String
1113 - Default: The hostname of the server
1114
1115 This is the server ID that will be returned on an EDNS NSID query.
1116
1117 .. _setting-only-notify:
1118
1119 ``only-notify``
1120 ---------------
1121
1122 - IP Ranges, separated by commas or whitespace
1123 - Default: 0.0.0.0/0, ::/0
1124
1125 For type=MASTER zones (or SLAVE zones with slave-renotify enabled)
1126 PowerDNS automatically sends NOTIFYs to the name servers specified in
1127 the NS records. By specifying networks/mask as whitelist, the targets
1128 can be limited. The default is to notify the world. To completely
1129 disable these NOTIFYs set ``only-notify`` to an empty value. Independent
1130 of this setting, the IP addresses or netmasks configured with
1131 :ref:`setting-also-notify` and ``ALSO-NOTIFY`` domain metadata
1132 always receive AXFR NOTIFYs.
1133
1134 IP addresses and netmasks can be excluded by prefixing them with a ``!``.
1135 To notify all IP addresses apart from the 192.168.0.0/24 subnet use the following::
1136
1137 only-notify=0.0.0.0/0, ::/0, !192.168.0.0/24
1138
1139 .. note::
1140 Even if NOTIFYs are limited by a netmask, PowerDNS first has to
1141 resolve all the hostnames to check their IP addresses against the
1142 specified whitelist. The resolving may take considerable time,
1143 especially if those hostnames are slow to resolve. If you do not need to
1144 NOTIFY the slaves defined in the NS records (e.g. you are using another
1145 method to distribute the zone data to the slaves), then set
1146 :ref:`setting-only-notify` to an empty value and specify the notification targets
1147 explicitly using :ref:`setting-also-notify` and/or
1148 :ref:`metadata-also-notify` domain metadata to avoid this potential bottleneck.
1149
1150 .. note::
1151 If your slaves support Internet Protocol version, which your master does not,
1152 then set ``only-notify`` to include only supported protocol version.
1153 Otherwise there will be error trying to resolve address.
1154
1155 For example, slaves support both IPv4 and IPv6, but PowerDNS master have only IPv4,
1156 so allow only IPv4 with ``only-notify``::
1157
1158 only-notify=0.0.0.0/0
1159
1160 .. _setting-out-of-zone-additional-processing:
1161
1162 ``out-of-zone-additional-processing``
1163 -------------------------------------
1164
1165 .. deprecated:: 4.2.0
1166 This setting has been removed.
1167
1168 - Boolean
1169 - Default: yes
1170
1171 Do out of zone additional processing. This means that if a malicious
1172 user adds a '.com' zone to your server, it is not used for other domains
1173 and will not contaminate answers. Do not enable this setting if you run
1174 a public DNS service with untrusted users.
1175
1176 The docs had previously indicated that the default was "no", but the
1177 default has been "yes" since 2005.
1178
1179 .. _setting-outgoing-axfr-expand-alias:
1180
1181 ``outgoing-axfr-expand-alias``
1182 ------------------------------
1183
1184 - Boolean
1185 - Default: no
1186
1187 If this is enabled, ALIAS records are expanded (synthesised to their
1188 A/AAAA) during outgoing AXFR. This means slaves will not automatically
1189 follow changes in those A/AAAA records unless you AXFR regularly!
1190
1191 If this is disabled (the default), ALIAS records are sent verbatim
1192 during outgoing AXFR. Note that if your slaves do not support ALIAS,
1193 they will return NODATA for A/AAAA queries for such names.
1194
1195 .. _setting-prevent-self-notification:
1196
1197 ``prevent-self-notification``
1198 -----------------------------
1199
1200 - Boolean
1201 - Default: yes
1202
1203 PowerDNS Authoritative Server attempts to not send out notifications to
1204 itself in master mode. In very complicated situations we could guess
1205 wrong and not notify a server that should be notified. In that case, set
1206 prevent-self-notification to "no".
1207
1208 .. _setting-query-cache-ttl:
1209
1210 ``query-cache-ttl``
1211 -------------------
1212
1213 - Integer
1214 - Default: 20
1215
1216 Seconds to store queries with an answer in the Query Cache. See :ref:`query-cache`.
1217
1218 .. _setting-query-local-address:
1219
1220 ``query-local-address``
1221 -----------------------
1222
1223 - IPv4 Address
1224 - Default: 0.0.0.0
1225
1226 The IP address to use as a source address for sending queries. Useful if
1227 you have multiple IPs and PowerDNS is not bound to the IP address your
1228 operating system uses by default for outgoing packets.
1229
1230 .. _setting-query-local-address6:
1231
1232 ``query-local-address6``
1233 ------------------------
1234
1235 - IPv6 Address
1236 - Default: '::'
1237
1238 Source IP address for sending IPv6 queries.
1239
1240 .. _setting-query-logging:
1241
1242 ``query-logging``
1243 -----------------
1244
1245 - Boolean
1246 - Default: no
1247
1248 Boolean, hints to a backend that it should log a textual representation
1249 of queries it performs. Can be set at runtime.
1250
1251 .. _setting-queue-limit:
1252
1253 ``queue-limit``
1254 ---------------
1255
1256 - Integer
1257 - Default: 1500
1258
1259 Maximum number of milliseconds to queue a query. See :doc:`performance`.
1260
1261 .. _setting-receiver-threads:
1262
1263 ``receiver-threads``
1264 --------------------
1265
1266 - Integer
1267 - Default: 1
1268
1269 Number of receiver (listening) threads to start. See :doc:`performance`.
1270
1271 .. _setting-recursive-cache-ttl:
1272
1273 ``recursive-cache-ttl``
1274 -----------------------
1275
1276 - Integer
1277 - Default: 10
1278
1279 .. deprecated:: 4.1.0
1280 Recursion has been removed, see :doc:`guides/recursion`
1281
1282 Seconds to store recursive packets in the :ref:`packet-cache`.
1283
1284 .. _setting-recursor:
1285
1286 ``recursor``
1287 ------------
1288
1289 - IP Address
1290
1291 .. deprecated:: 4.1.0
1292 Recursion has been removed, see :doc:`guides/recursion`
1293
1294 If set, recursive queries will be handed to the recursor specified here.
1295
1296 .. _setting-resolver:
1297
1298 ``resolver``
1299 ------------
1300
1301 - IP Addresses with optional port, separated by commas
1302
1303 .. versionadded:: 4.1.0
1304
1305 Use these resolver addresses for ALIAS and the internal stub resolver.
1306 If this is not set, ``/etc/resolv.conf`` is parsed for upstream
1307 resolvers.
1308
1309 .. _setting-retrieval-threads:
1310
1311 ``retrieval-threads``
1312 ---------------------
1313
1314 - Integer
1315 - Default: 2
1316
1317 Number of AXFR slave threads to start.
1318
1319 .. _setting-send-signed-notify:
1320
1321 ``send-signed-notify``
1322 ----------------------
1323
1324 - Boolean
1325 - Default: yes
1326
1327 If yes, outgoing NOTIFYs will be signed if a TSIG key is configured for the zone.
1328 If there are multiple TSIG keys configured for a domain, PowerDNS will use the
1329 first one retrieved from the backend, which may not be the correct one for the
1330 respective slave. Hence, in setups with multiple slaves with different TSIG keys
1331 it may be required to send NOTIFYs unsigned.
1332
1333 .. _setting-setgid:
1334
1335 ``setgid``
1336 ----------
1337
1338 - String
1339
1340 If set, change group id to this gid for more security. See :doc:`security`.
1341
1342 .. _setting-setuid:
1343
1344 ``setuid``
1345 ----------
1346
1347 - String
1348
1349 If set, change user id to this uid for more security. See :doc:`security`.
1350
1351 .. _setting-slave:
1352
1353 ``slave``
1354 ---------
1355
1356 - Boolean
1357 - Default: no
1358
1359 Turn on slave support. See :ref:`slave-operation`.
1360
1361 .. _setting-slave-cycle-interval:
1362
1363 ``slave-cycle-interval``
1364 ------------------------
1365
1366 - Integer
1367 - 60
1368
1369 On a master, this is the amounts of seconds between the master checking
1370 the SOA serials in its database to determine to send out NOTIFYs to the
1371 slaves. On slaves, this is the number of seconds between the slave
1372 checking for updates to zones.
1373
1374 .. _setting-slave-renotify:
1375
1376 ``slave-renotify``
1377 ------------------
1378
1379 - Boolean
1380 - Default: no
1381
1382 This setting will make PowerDNS renotify the slaves after an AXFR is
1383 *received* from a master. This is useful when using when running a
1384 signing-slave.
1385
1386 .. _setting-signing-threads:
1387
1388 ``signing-threads``
1389 -------------------
1390
1391 - Integer
1392 - Default: 3
1393
1394 Tell PowerDNS how many threads to use for signing. It might help improve
1395 signing speed by changing this number.
1396
1397 .. _setting-soa-expire-default:
1398
1399 ``soa-expire-default``
1400 ----------------------
1401
1402 - Integer
1403 - Default: 604800
1404
1405 Default :ref:`types-soa` expire.
1406
1407 .. _setting-soa-minimum-ttl:
1408
1409 ``soa-minimum-ttl``
1410 -------------------
1411
1412 - Integer
1413 - Default: 3600
1414
1415 Default :ref:`types-soa` minimum ttl.
1416
1417 .. _setting-soa-refresh-default:
1418
1419 ``soa-refresh-default``
1420 -----------------------
1421
1422 - Integer
1423 - Default: 10800
1424
1425 Default :ref:`types-soa` refresh.
1426
1427 .. _setting-soa-retry-default:
1428
1429 ``soa-retry-default``
1430 ---------------------
1431
1432 - Integer
1433 - Default: 3600
1434
1435 Default :ref:`types-soa` retry.
1436
1437 .. _setting-socket-dir:
1438
1439 ``socket-dir``
1440 --------------
1441
1442 - Path
1443
1444 Where the controlsocket will live. The default depends on
1445 ``LOCALSTATEDIR`` during compile-time (usually ``/var/run`` or
1446 ``/run``). See :ref:`control-socket`.
1447
1448 This path will also contain the pidfile for this instance of PowerDNS
1449 called ``pdns.pid`` by default. See :ref:`setting-config-name`
1450 and :doc:`Virtual Hosting <guides/virtual-instances>` how this can differ.
1451
1452 .. _setting-supermaster:
1453
1454 ``supermaster``
1455 ---------------
1456
1457 - Boolean
1458 - Default: no
1459
1460 .. versionadded:: 4.2.0
1461
1462 Turn on supermaster support. See :ref:`supermaster-operation`.
1463
1464 .. _setting-tcp-control-address:
1465
1466 ``tcp-control-address``
1467 -----------------------
1468
1469 - IP Address
1470
1471 Address to bind to for TCP control.
1472
1473 .. _setting-tcp-control-port:
1474
1475 ``tcp-control-port``
1476 --------------------
1477
1478 - Integer
1479 - Default: 53000
1480
1481 Port to bind to for TCP control.
1482
1483 .. _setting-tcp-control-range:
1484
1485 ``tcp-control-range``
1486 ---------------------
1487
1488 - IP Ranges, separated by commas or whitespace
1489
1490 Limit TCP control to a specific client range.
1491
1492 .. _setting-tcp-control-secret:
1493
1494 ``tcp-control-secret``
1495 ----------------------
1496
1497 - String
1498
1499 Password for TCP control.
1500
1501 .. _setting-tcp-fast-open:
1502
1503 ``tcp-fast-open``
1504 -----------------
1505
1506 - Integer
1507 - Default: 0 (Disabled)
1508
1509 .. versionadded:: 4.1.0
1510
1511 Enable TCP Fast Open support, if available, on the listening sockets.
1512 The numerical value supplied is used as the queue size, 0 meaning
1513 disabled.
1514
1515 .. _setting-tcp-idle-timeout:
1516
1517 ``tcp-idle-timeout``
1518 --------------------
1519
1520 - Integer
1521 - Default: 5
1522
1523 Maximum time in seconds that a TCP DNS connection is allowed to stay
1524 open while being idle, meaning without PowerDNS receiving or sending
1525 even a single byte.
1526
1527 .. _setting-traceback-handler:
1528
1529 ``traceback-handler``
1530 ---------------------
1531
1532 - Boolean
1533 - Default: yes
1534
1535 Enable the Linux-only traceback handler.
1536
1537 .. _setting-trusted-notification-proxy:
1538
1539 ``trusted-notification-proxy``
1540 ------------------------------
1541
1542 - String
1543
1544 IP address of incoming notification proxy
1545
1546 .. _setting-udp-truncation-threshold:
1547
1548 ``udp-truncation-threshold``
1549 ----------------------------
1550
1551 - Integer
1552 - Default: 1232
1553
1554 EDNS0 allows for large UDP response datagrams, which can potentially
1555 raise performance. Large responses however also have downsides in terms
1556 of reflection attacks. Maximum value is 65535, but values above
1557 4096 should probably not be attempted.
1558
1559 .. note:: Why 1232?
1560
1561 1232 is the largest number of payload bytes that can fit in the smallest IPv6 packet.
1562 IPv6 has a minimum MTU of 1280 bytes (:rfc:`RFC 8200, section 5 <8200#section-5>`), minus 40 bytes for the IPv6 header, minus 8 bytes for the UDP header gives 1232, the maximum payload size for the DNS response.
1563
1564 .. _setting-version-string:
1565
1566 ``version-string``
1567 ------------------
1568
1569 - Any of: ``anonymous``, ``powerdns``, ``full``, String
1570 - Default: full
1571
1572 When queried for its version over DNS
1573 (``dig chaos txt version.bind @pdns.ip.address``), PowerDNS normally
1574 responds truthfully. With this setting you can overrule what will be
1575 returned. Set the ``version-string`` to ``full`` to get the default
1576 behaviour, to ``powerdns`` to just make it state
1577 ``served by PowerDNS - http://www.powerdns.com``. The ``anonymous``
1578 setting will return a ServFail, much like Microsoft nameservers do. You
1579 can set this response to a custom value as well.
1580
1581 .. _setting-webserver:
1582
1583 ``webserver``
1584 -------------
1585
1586 - Boolean
1587 - Default: no
1588
1589 Start a webserver for monitoring. See :doc:`performance`".
1590
1591 .. versionchanged:: 4.1.0
1592 It was necessary to enable the webserver to use the REST API, this is no longer the case.
1593
1594 .. _setting-webserver-address:
1595
1596 ``webserver-address``
1597 ---------------------
1598
1599 - IP Address
1600 - Default: 127.0.0.1
1601
1602 IP Address for webserver/API to listen on.
1603
1604 .. _setting-webserver-allow-from:
1605
1606 ``webserver-allow-from``
1607 ------------------------
1608
1609 - IP ranges, separated by commas or whitespace
1610 - Default: 127.0.0.1,::1
1611
1612 .. versionchanged:: 4.1.0
1613
1614 Default is now 127.0.0.1,::1, was 0.0.0.0/0,::/0 before.
1615
1616 Webserver/API access is only allowed from these subnets.
1617
1618 .. _setting-webserver-loglevel:
1619
1620 ``webserver-loglevel``
1621 ----------------------
1622 .. versionadded:: 4.2.0
1623
1624 - String, one of "none", "normal", "detailed"
1625
1626 The amount of logging the webserver must do. "none" means no useful webserver information will be logged.
1627 When set to "normal", the webserver will log a line per request that should be familiar::
1628
1629 [webserver] e235780e-a5cf-415e-9326-9d33383e739e 127.0.0.1:55376 "GET /api/v1/servers/localhost/bla HTTP/1.1" 404 196
1630
1631 When set to "detailed", all information about the request and response are logged::
1632
1633 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Request Details:
1634 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Headers:
1635 [webserver] e235780e-a5cf-415e-9326-9d33383e739e accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
1636 [webserver] e235780e-a5cf-415e-9326-9d33383e739e accept-encoding: gzip, deflate
1637 [webserver] e235780e-a5cf-415e-9326-9d33383e739e accept-language: en-US,en;q=0.5
1638 [webserver] e235780e-a5cf-415e-9326-9d33383e739e connection: keep-alive
1639 [webserver] e235780e-a5cf-415e-9326-9d33383e739e dnt: 1
1640 [webserver] e235780e-a5cf-415e-9326-9d33383e739e host: 127.0.0.1:8081
1641 [webserver] e235780e-a5cf-415e-9326-9d33383e739e upgrade-insecure-requests: 1
1642 [webserver] e235780e-a5cf-415e-9326-9d33383e739e user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:64.0) Gecko/20100101 Firefox/64.0
1643 [webserver] e235780e-a5cf-415e-9326-9d33383e739e No body
1644 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Response details:
1645 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Headers:
1646 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Connection: close
1647 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Content-Length: 49
1648 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Content-Type: text/html; charset=utf-8
1649 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Server: PowerDNS/0.0.15896.0.gaba8bab3ab
1650 [webserver] e235780e-a5cf-415e-9326-9d33383e739e Full body:
1651 [webserver] e235780e-a5cf-415e-9326-9d33383e739e <!html><title>Not Found</title><h1>Not Found</h1>
1652 [webserver] e235780e-a5cf-415e-9326-9d33383e739e 127.0.0.1:55376 "GET /api/v1/servers/localhost/bla HTTP/1.1" 404 196
1653
1654 The value between the hooks is a UUID that is generated for each request. This can be used to find all lines related to a single request.
1655
1656 .. note::
1657 The webserver logs these line on the NOTICE level. The :ref:`settings-loglevel` seting must be 5 or higher for these lines to end up in the log.
1658
1659 .. _setting-webserver-password:
1660
1661 ``webserver-password``
1662 ----------------------
1663
1664 - String
1665
1666 The plaintext password required for accessing the webserver.
1667
1668 .. _setting-webserver-port:
1669
1670 ``webserver-port``
1671 ------------------
1672
1673 - Integer
1674 - Default: 8081
1675
1676 The port where webserver/API will listen on.
1677
1678 .. _setting-webserver-print-arguments:
1679
1680 ``webserver-print-arguments``
1681 -----------------------------
1682
1683 - Boolean
1684 - Default: no
1685
1686 If the webserver should print arguments.
1687
1688 .. _setting-write-pid:
1689
1690 ``write-pid``
1691 -------------
1692
1693 - Boolean
1694 - Default: yes
1695
1696 If a PID file should be written.
1697
1698 .. _setting-xfr-max-received-mbytes:
1699
1700 ``xfr-max-received-mbytes``
1701 ---------------------------
1702
1703 - Integer
1704 - Default: 100
1705
1706 Specifies the maximum number of received megabytes allowed on an
1707 incoming AXFR/IXFR update, to prevent resource exhaustion. A value of 0
1708 means no restriction.