another nsupdate question
Kevin Darcy
kcd at daimlerchrysler.com
Tue Jul 3 22:51:45 UTC 2001
Charles Bodley wrote:
> The examples below show how nsupdate could be used to insert and delete
> resource records from the example.com zone. Notice that the input in
> each example contains a trailing blank line so that a group of commands
> are sent as one dynamic update request to the master name server for
> example.com.
>
> # nsupdate
> > update delete oldhost.example.com A
> > update add newhost.example.com 86400 A 172.16.1.1
> >
> Is there anyway to just update not remove then re-add? According to the man
> page it's sent as one request does this mean that if it fails nothing
> happens or can it fail in such away that there in no record left?
The only record type that can be atomically replaced is SOA. See the
infamously-unclear Section 3.4.2.2 of RFC 2136. You have to make sure, however,
that the SOA.SERIAL of the new record is higher (according to serial-number
arithmetic) than the SOA.SERIAL of the old record.
In nsupdate terms, just "update add" the new SOA record and it should replace
the old one.
- Kevin
More information about the bind-users
mailing list