B10-DBUTIL(8)

NAME
b10-dbutil - Zone Database Maintenance Utility

SYNOPSIS

b10-dbutil --check [--verbose] [--quiet] [dbfile]

b10-dbutil --upgrade [--noconfirm] [--verbose] [--quiet] [dbfile]

DESCRIPTION

The b10-dbutil utility is a general administration utility for SQL databases for BIND 10. (Currently only SQLite is supported by BIND 10.) It can report the current verion of the schema, and upgrade an existing database to the latest version of the schema.

b10-dbutil operates in one of two modesr: check mode or upgrade mode.

In check mode (b10-dbutil --check), the utility reads the version of the database schema from the database and prints it. It will tell you whether the schema is at the latest version supported by BIND 10. Exit status is 0 if the schema is at the correct version, 1 if the schema is at an older version, or 2 if the schema is at a version not yet supported by this version of b10-dbutil. Any higher value indicates an error during command-line parsing or execution.

When the upgrade function is selected (b10-dbutil --upgrade), the utility takes a copy of the database, then upgrades it to the latest version of the schema. The contents of the database remain intact. (The backup file is a file in the same directory as the database file. It has the same name, with ".backup" appended to it. If a file of that name already exists, the file will have the suffix ".backup-1". If that exists, the file will be suffixed ".backup-2", and so on). Exit status is 0 if the upgrade is either succesful or aborted by the user, and non-zero if there is an error.

When upgrading the database, it is strongly recommended that BIND 10 not be running while the upgrade is in progress.

ARGUMENTS

The arguments are as follows:

--check
    Selects the version check function, which reports the current version of the database. This is mutually exclusive with the --upgrade option.

--noconfirm
    Only valid with --upgrade, this disables the prompt. Normally the utility will print a warning that an upgrade is about to take place and request that you type "Yes" to continue. If this switch is given on the command line, no prompt will be issued and the utility will just perform the upgrade.

--upgrade
    Selects the upgrade function, which upgrades the database to the latest version of the schema. This is mutually exclusive with the --check option.

    The upgrade function will upgrade a BIND 10 database — no matter how old the schema — preserving all data. A backup file is created before the upgrade (with the same name as the database, but with ".backup" suffixed to it). If the upgrade fails, this file can be copied back to restore the original database.

--verbose
    Enable verbose mode. Each SQL command issued by the utility will be printed to STDERR before it is executed.

--quiet
    Enable quiet mode. No output is printed, except errors during command-line argument parsing, or the user confirmation dialog.

dbfile
    Name of the database file to check or upgrade.

COPYRIGHT
Copyright © 2012 Internet Systems Consortium, Inc. ("ISC")