From 7a58dc4cc65f107b2a05951cee13c71dbc7b4264 Mon Sep 17 00:00:00 2001 From: Pieter Lexis Date: Fri, 2 Jun 2017 11:55:11 +0200 Subject: [PATCH] Docs: add pdnsutil examples to domain metadata --- docs/markdown/authoritative/domainmetadata.md | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/docs/markdown/authoritative/domainmetadata.md b/docs/markdown/authoritative/domainmetadata.md index c8c9ce6b80..1d69d69e23 100644 --- a/docs/markdown/authoritative/domainmetadata.md +++ b/docs/markdown/authoritative/domainmetadata.md @@ -12,15 +12,22 @@ settings. For the implementation in non-sql backends, please review your backend's documentation. +Apart from raw SQL statements, setting domain metadata can be done with [`pdnsutil set-meta`](dnssec.md#pdnsutil) and retrieving metadata is done with [`pdnsutil get-meta`](dnssec.md#pdnsutil). + ## ALLOW-AXFR-FROM Starting with the PowerDNS Authoritative Server 3.1, per-zone AXFR ACLs can be stored in the domainmetadata table. -Each ACL row can list one subnet (v4 or v6), or the magical value 'AUTO-NS' that -tries to allow all potential slaves in. +Each ACL specifies one subnet (v4 or v6), or the magical value 'AUTO-NS' that tries to allow all potential slaves in. Example: +``` +pdnsutil set-meta powerdns.org ALLOW-AXFR-FROM AUTO-NS 2001:db8::/48 +``` + +Each ACL has its own row in the database: + ``` select id from domains where name='example.com'; 7 @@ -40,6 +47,13 @@ See the documentation on [Dynamic DNS update](dnsupdate.md) When notifying this domain, also notify this nameserver (can occur multiple times). The nameserver may have contain an optional port number. e.g.: +``` +pdnsutil set-meta powerdns.org ALSO-NOTIFY 192.0.2.1:5300 +pdnsutil set-meta powerdns.org ALLOW-AXFR-FROM 2001:db8:53::1 +``` + +Or in SQL: + ``` insert into domainmetadata (domain_id, kind, content) values (7,'ALSO-NOTIFY','192.0.2.1:5300'); insert into domainmetadata (domain_id, kind, content) values (7,'ALLOW-AXFR-FROM','2001:db8:53::1'); -- 2.47.2