0

On PowerDNS on a Raspberry, I have recursor pointing to Google (8.8.8.8) and only one zone file and it contains:

$ORIGIN abc.co.uk.
$TTL 1h
@ IN SOA ns.abc.co.uk. hostmaster.abc.co.uk. (
  1; serial
  1d; refresh
  2h; retry
  4w; expire
  1h; minimum time-to-live
  )
  IN NS ns
  IN A 1.2.3.4
www IN CNAME def.com.
ns IN A 192.168.9.100

Querying for abc.co.uk works, but www.abc.co.uk does not return a CNAME of def.com. What could be the cause of the error? The nslookup output is as follows (with annotations):

> set type=any
> abc.co.uk
Server:         192.168.9.100
Address:        192.168.9.100#53

abc.co.uk       nameserver = ns.abc.co.uk.
abc.co.uk
    origin = ns.abc.co.uk
    mail addr = hostmaster.abc.co.uk
    serial = 1
    refresh = 86400
    retry = 7200
    expire = 2419200
    minimum = 3600
Name:   abc.co.uk
Address: 1.2.3.4      // looks ok?

> www.abc.co.uk
Server:         192.168.9.100
Address:        192.168.9.100#53

Non-authoritative answer:
www.abc.co.uk   canonical name = abc.co.uk.    //!! result from Google?

Authoritative answers can be found from:

If I omit the period after def.com in the CNAME line in the zone file, then the query returns:

> www.abc.co.uk
Server:         192.168.9.100
Address:        192.168.9.100#53

www.abc.co.uk   canonical name = def.com.abc.co.uk.
Old Geezer
  • 355
  • 7
  • 21

1 Answers1

0

I removed and purged pdns-server, reinstalled, and it worked as expected.

Old Geezer
  • 355
  • 7
  • 21