Note In the future, support for SQL Server device mirroring may be discontinued. It is recommended that you use either the mirroring functionality of the Microsoft Windows NT operating system, or hardware-based mirroring if your hardware supports it. For more information about Windows NT mirroring, see the Microsoft Windows NT operating system documentation in What's New for SQL Server 6.5.
Disk mirroring allows a software mirror of a user database device or the MASTER database device to add to the recoverability options available for the database or databases that reside on that device. When a database resides on multiple devices, mirror all the devices to ensure that the whole database is mirrored. If a database device fails, its mirror immediately takes over; database users are unaffected and can continue to access data without interruption.
You can mirror or unmirror database devices without shutting down SQL Server. Disk mirroring does not interfere with ongoing activities in the database.
For even greater protection, always put the log portion of the database on a separate device from the data portion (see the LOG ON clause of the CREATE DATABASE statement). Whenever possible, this device should also be on a separate physical device.
For a report on all the SQL Server devices on your system (user database devices and their mirrors, as well as dump devices), execute the sp_helpdevice system stored procedure.
SQL Server device mirroring for all user-defined devices consists of three statements (discussed in the following sections).
Software device mirroring can be set up by the system administrator.
Note To mirror the MASTER device, use the -r option (with the sqlservr command-line executable) and the name of the mirror when you restart SQL Server. To add the -r option as a parameter, choose the Parameters button in the Set Server Options dialog box provided with the SQL Setup Utility. For more information, see Microsoft SQL Server Setup.
Other SQL Server fault-tolerance options include hardware fault tolerance and operating-system software fault tolerance. For more information, see the Microsoft SQL Server Administrator's Companion.