updsoa.pl - update DNS SOA record
This script updates the serial number in soa_file. The serial number is formatted as yyyymmddnn where nn differentiates between multiple updates on the same day. For zones with serious flux, the -u uses UTC as the serial number.
The previous version of soa_file is left in soa_file.old
If soa_file does not exist, we create it. Various options are used to control the content of the SOA record, and we also look for .${Myname}rc.pl to read default values from.
To cater for magic domains (eg. round-robin zones) we check for each of the SOA fields in the associative arrays SOA_field. Thus .${Myname}rc.pl might contain $SOA_m{rr.crufty.net} = 0 to set the mimimum TTL to 0.
The command line options set the default values for the SOA fields.
BIND-8.2.2 requires the $TTL record appear before any other including the SOA record, otherwise it issues a warning about using the SOA minimum TTL field instead.
Simon J. Gerraty <sjg@crufty.net>