Skip to content
Command Line Interface

Zone_prefs.sh

This script allows you to manage the DNS zone records as well as update DNS zone SOA records.

Usage

bash
zone_prefs.sh <command> <login_name> <options>

Examples

In these examples, you are logged in as root and you call the scripts by their directory.

Add New Record

bash
zone_prefs.sh --create "foo.bar." \
  --record_type "A" \
  --record_host "foo.bar." \
  --record_value "123.213.123.123"
bash
zone_prefs.sh --create "0.3.6.6.IN-ADDR.ARPA." \
    --record_type "PTR"  \
    --record_host "10.0.3.6.6.IN-ADDR.ARPA."  \
    --record_value "foo.bar."

Add New Record Using Non FQDN Hosts

bash
zone_prefs.sh --create "foo.bar."  \
    --record_type "A"  \
    --record_host "not-fqdn"  \
    --record_value "123.213.123.123"
bash
zone_prefs.sh --create "0.3.6.6.IN-ADDR.ARPA."  \
    --record_type "PTR"  \
    --record_host "11"  \
    --record_value "foo.bar."

Add New NAPTR Record

bash
zone_prefs.sh --create "1.2.3.1.1.2.3.1.E164.ARPA."  \
    --record_type "NAPTR"  \
    --record_services "sip+E2U"  \
    --record_order "10"  \
    --record_preference "100"  \
    --record_search "^.*$"  \
    --record_replace "sip:information@foo.bar"  \
    --record_case "i"  \
    --record_flag "u"  \
    --record_replacement "."

Add New SRV Record

bash
zone_prefs.sh --create "foo.bar."  \
    --record_type "SRV"  \
    --record_host "test"  \
    --record_ttl "10"  \
    --record_service "asr"  \
    --record_protocol "tcp"  \
    --record_priority "4"  \
    --record_weight "10"  \
    --record_port "123"  \
    --record_target "outside2.foo.bar."

Update Zone's SOA Records

bash
zone_prefs.sh --update "foo.bar."  \
    --zone_serial "10000"  \
    --zone_refresh "10000"  \
    --retry_time "10000"
Last updated: Dec 10, 2025