Suspends disk mirroring initiated with the disk mirror command to allow hardware maintenance or the changing of a hardware device.
disk unmirror name = "device_name" [, side = {"primary" | secondary}] [, mode = {retain | remove}]
I/O is directed only at the device not being unmirrored.
The status column of sysdevices indicates that mirroring is deactivated. remove eliminates all sysdevices references to a mirror device.
The status column indicates that the mirroring feature is ignored.
The phyname column is replaced by the name of the secondary device in the mirrorname column if the primary device is the one being deactivated.
The mirrorname column is set to NULL.
disk unmirror name = "user_disk"
disk unmirror name = "user_disk", side = secondary
disk unmirror name = "user_disk", mode = remove
Disk mirroring creates a software mirror of a user database device, the master database device, or a database device used for user database transaction logs. If a database device fails, its mirror immediately takes over.
disk unmirror disables either the original database device or the mirror, either permanently or temporarily, so that the device is no longer available to the SAP ASE server for reads or writes. It does not remove the associated file from the operating system.
Disk unmirroring alters the sysdevices table in the master database. Back up the master database with the dump database command after each use of disk unmirror. This makes recovery easier and safer in case master is damaged.
You can unmirror a database device while it is in use.
You cannot unmirror any of a database’s devices while a dump database, load database, or load transaction is in progress. The SAP ASE server displays a message asking whether to abort the dump or load or to defer the disk unmirror until after the dump or load completes.
You cannot unmirror a database’s log device while a dump transaction is in progress. The SAP ASE server displays a message asking whether to abort the dump or defer the disk unmirror until after the dump completes.
Mirror all the default database devices so that you are still protected if a create or alter database command affects a database device in the default list.
When a read or write to a mirrored device is unsuccessful, the SAP ASE server automatically unmirrors the bad device and prints error messages. The SAP ASE server continues to run, unmirrored. A system administrator must restart mirroring with the disk remirror command.
For a report on all SAP ASE devices on your system (user database devices and their mirrors, as well as dump devices), execute sp_helpdevice.
Use disk remirror to reestablish mirroring after it is temporarily stopped with the mode = retain option of the disk unmirror command. If mirroring is permanently disabled with the mode = remove option, you must remove the operating system file that contains the mirror before using disk remirror.
sp_diskdefault, sp_helpdevice, sp_logdevice in Reference Manual: Procedures
dataserver, startserver in the Utility Guide
ANSI SQL – Compliance level: Transact-SQL extension.
The permission checks for disk unmirror differ based on your granular permissions settings. You must be using the master database to use disk unmirror.
Setting | Description |
---|---|
Enabled | With granular permissions enabled, you must be a user with manage disk privilege. |
Disabled | With granular permissions disabled, you must be a user with sa_role. disk unmirror permission is not transferable. |
Values in event and extrainfo columns of sysaudits are:
Information | Values |
---|---|
Event | 24 |
Audit option | disk |
Command or access audited | disk unmirror |
Information in extrainfo |
|