SQLServer 复制和数据库镜像 详细配置部署
https://blog.csdn.net/kk185800961/article/details/46369577
SQL Server扫盲系列——镜像篇
https://blog.csdn.net/dba_huangzj/article/details/35995083 ALTER DATABASE (Transact-SQL) Database Mirroring
https://docs.microsoft.com/en-us/sql/t-sql/statements/alter-database-transact-sql-database-mirroring?view=sql-server-2017
USE [master]
95.GO
96.--主体执行:设置为高安全模式(同步)
97.ALTER DATABASE [MyDB] SET SAFETY FULL
98.
99.--主体执行:设置为高性能模式(异步)
100.ALTER DATABASE [MyDB] SET SAFETY OFF
101.
102.--主体执行:主体与镜像切换
103.ALTER DATABASE [MyDB] SET PARTNER FAILOVER;
104.
105.
106.ALTER DATABASE [MyDB] SET PARTNER RESUME; --恢复镜像
107.ALTER DATABASE [MyDB] SET PARTNER FAILOVER; --切换主备
108.ALTER DATABASE [MyDB] SET PARTNER FORCE_SERVICE_ALLOW_DATA_LOSS; --强制恢复镜像
109.ALTER DATABASE [MyDB] SET ONLINE; --在线数据库
110.
111.
112.select * from sys.certificates
113.select * from sys.endpoints
114.select * from sys.database_mirroring_endpoints
115.select * from sys.database_mirroring
116.select * from sys.database_mirroring_witnesses
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。