I have added a zone test.net via rndc locally and it is working fine. Next, I want to update it via nsupdate but locally, my zone configurations are,
zone test.net {type master; file "zones-remote/masters/test.net" ; allow-update{localhost;};};
When I do this,
nsupdate
server localhost
zone sample.test.net
update add sample.test.net 86400 A 134.23.32.4
send
It gives the error "update failed: NOTAUTH"
Checking it via show, prior to send gives,
Outgoing update query:
;; ->>HEADER<<- opcode: UPDATE, status: NOERROR, id: 0
;; flags:; ZONE: 0, PREREQ: 0, UPDATE: 0, ADDITIONAL: 0
;; ZONE SECTION:
;test.net. IN SOA
;; UPDATE SECTION:
sample.test.net. 86400 IN A 134.23.32.4
When I try,
nsupdate
server localhost
zone test.net # Actual zone name
update add sample.test.net 86400 A 134.23.32.4
send
then the error "SERVFAIL" appears.
My zone file looks like this,
@ 86400 IN SOA test.net. sampling.gmail.com. (
2014101001
3h
1h
1w
30m86400s)
@ 84600 NS ns1.test.net.
@ 84600 IN A 42.42.42.42
ns1 84600 IN A 42.42.42.42
This zone file is correct and it resolves the query against its domain.