sys.database_mirroring_witnesses (Transact-SQL)

Contains a row for every witness role that a server plays in a database mirroring partnership.

Column name Data type Description

database_name

sysname

Name of the two copies of the database in the database mirroring session.

principal_server_name

sysname

Name of partner server whose copy of the database is currently the principal database.

mirror_server_name

sysname

Name of the partner server whose copy of the database is currently the mirror database.

safety_level

tinyint

Transaction safety setting for updates on the mirror database:

0 = Unknown state

1 = Off (asynchronous)

2 = Full (synchronous)

Using a witness for automatic failover requires full transaction safety, which is the default.

safety_level_desc

nvarchar(60)

Description of safety guarantee of updates on the mirror database:

UNKNOWN

OFF

FULL

safety_sequence_number

int

Update sequence number for changes to safety_level.

role_sequence_number

int

Update sequence number for changes to principal/mirror roles played by the mirroring partners.

mirroring_guid

uniqueidentifier

Identifier of the mirroring partnership.

family_guid

uniqueidentifier

Identifier of the backup family for the database. Used for detecting matching restore states.

is_suspended

bit

Database mirroring is suspended.

is_suspended_sequence_number

int

Sequence number for setting is_suspended.

See Also

Reference

sys.database_mirroring (Transact-SQL)
sys.database_mirroring_endpoints (Transact-SQL)
Catalog Views (Transact-SQL)

Other Resources

Querying the SQL Server System Catalog FAQ

Help and Information

Getting SQL Server 2005 Assistance