PowerDNS LDAP Backend LDIF Format

This configuration assumes that reverse lookups are derived from the standard host entries rather than being in a separate tree.

From the PowerDNS manual

Package: pdns-server

SOA Record (defines nameserver root)

SOA Record Line

The stored format is:

   primary hostmaster serial refresh retry expire default_ttl

SOA Fields

Besides the primary and the hostmaster, all fields are numerical. PDNS has a set of default values:

SOA fields

primary

default-soa-name configuration option

hostmaster

hostmaster@domain-name

serial

0

refresh

10800 (3 hours)

retry

3600 (1 hour)

expire

604800 (1 week)

default_ttl

3600 (1 hour)

The fields have complicated and sometimes controversial meanings. The 'serial' field is special. If left at 0, the default, PDNS will perform an internal list of the domain to determine highest change_date field of all records within the zone, and use that as the zone serial number. This means that the serial number is always raised when changes are made to the zone, as long as the change_date field is being set.

DanielDickinson's Summary

The LdapDn for SOA Record

Skeleton

 dn: dc=ldap-dns-basedn-name,BaseDN DNS]
 objectclass: dnsdomain
 objectclass: domainrelatedobject
 dc: ldap-dns-basedn-name
 soarecord: primary hostmaster serial refresh retry expire default_ttl
 nsrecord: nameserver-hostname.your.domain
 mxrecord: 10 mail-server.your.mail
 associateddomain: your.domain

Example

 dn: dc=example,ou=dns,dc=example,dc=com
 objectClass: dnsDomain
 objectClass: domainrelatedobject
 dc: example
 soarecord: main.example.com hostmaster@mail.example.com 0 1800 3600 604800 84600
 nsrecord: georges.example.com
 mxrecord: 10 winnifred.example.com
 associateddomain: example.com

A Host Record

Skeleton

Example

 dn: dc=roger,dc=example,ou=dns,dc=example,dc=com
 objectclass: top
 objectclass: dnsdomain
 objectclass domainrelatedobject
 dc: roger
 arecord: 192.168.1.2
 associateddomain: roger.example.com

An alias (CNAME/PTR) Record

Skeleton

 # Other names for hostname.your.domain
 dn: dc=hostname-aliases,dc=ldap-dns-basedn-name,BaseDN DNS]
 objectclass: top
 objectclass: dnsdomain
 objectclass: domainrelatedobject
 dc: hostname-aliases
 cnamerecord: hostname.your.domain
 associateddomain: alias1.your.domain
 associateddomain: alias2.your.domain
 associateddomain: alias3.your.domain
 associateddomain: alias4.your.domain

Example

 # Other names for roger.example.com
 dn: dc=roger-aliases,dc=example,ou=dns,dc=example,dc=com
 objectclass: top
 objectclass: dnsdomain
 objectclass: domainrelatedobject
 dc: roger-aliases
 cnamerecord: roger.example.com
 associateddomain: time.example.com
 associateddomain: mail.example.com
 associateddomain: winnifred.example.com
 associateddomain: news.example.com

A SRV Record

SRV Records are commonly used to (as in this example XMPP also known as Jabber) tell clients which servers provide a certain service.

You will need the dnsdomain2.schema here to use this entry.

The schema should be included in the sources. Don't know for sure I use the debian package from etch.

Skeleton

dn: dc=srv-records,dc=example,ou=dns,dc=example,dc=com
objectClass: dNSDomain
objectClass: dNSDomain2
objectClass: domain
objectClass: domainRelatedObject
objectClass: top
associatedDomain: _service._protocol.example.com
dc: srv-records
sRVRecord: <WEIGHT> <PRIORITY> <PORT> <TARGET>

Example

dn: dc=srv-records,dc=example,ou=dns,dc=example,dc=com
objectClass: dNSDomain
objectClass: dNSDomain2
objectClass: domain
objectClass: domainRelatedObject
objectClass: top
associatedDomain: _jabber._tcp.example.com
dc: srv-records
sRVRecord: 5 0 5269 jabber.example.com