unmount

Description

Shuts down the database and drops it from the Adaptive Server. The devices are also deactivated and dropped. The database and its pages are not altered when they are unmounted. The database pages remain on the OS devices. Once the unmount command completes, you can disconnect and move the devices at the source Adaptive Server if necessary. Use the manifest_file extension to create the manifest file for use at the secondary Adaptive Server.

The unmount command limits the number of databases to eight in a single command.

WARNING! The unmount command removes a database and all its information from the Adaptive Server. Use the unmount command only when you want to remove the database from one Adaptive Server to another Adaptive Server.

Syntax

unmount database dbname_list to manifest_file

Parameters

dbname_list

the database being unmounted. You can unmount more than one database.

manifest_file

the binary file that describes the databases that are present on a set of database devices. It can be created only if the set of databases that occupy those devices are isolated and self-contained on those devices.

Since the manifest file is a binary file, operations that perform character translations of the file contents (such as ftp) will corrupt the file unless done in binary mode.

Examples

Example 1

unmount databases from an Adaptive Server and create the manifest file for the database:

unmount database pubs2 to "/work2/Devices/Mpubs2_file"

Example 2

The encryption key created in key_db has been used to encrypt columns in col_db. These commands successfully unmount the named databases:

unmount database key_db, col_db
unmount database key_db with override
unmount database col_db with override 

Usage

You cannot:


Cluster edition

mount database and unmount database are supported in the Cluster Edition. However, these commands may be aborted if an instance failover recovery takes place while you are using these commands. In this case, the user must re-issue the command when the instance failover recovery is complete.


Encrypted columns and unmount database

These commands will fail with an error message without the override:

unmount database key_db
unmount database col_db

Standards

ANSI SQL – Compliance level: Entry-level compliant.

Auditing

Values in event and extrainfo columns of sysaudits are:

Event

Audit option

Command or access audited

Information in extrainfo

102

unmount

unmount database

  • Roles – Current active roles

  • Keywords or options – NULL

  • Previous value – NULL

  • Current value – NULL

  • Other information – NULL

  • Proxy information – Original login name, if a set proxy is in effect

See also

Commands mount, quiesce database