Steps:

1. backup database TestMirror on Pricipal server

2. backup database log of
TestMirror on Pricipal server

3. copy db and log backup files to Mirror server

4. restore db with norecovery

5. restore log with norecovery

6. create endpoints on both
Pricipal serverand Mirror server

Issue:

If you use sql command or Mirror wizard to set mirror machine.

It will show error: "The remote copy of database "DBmirrorTest" has not been rolled forward to a point in time that is encompassed in the local copy of the database log."

Or

1.  ALTERDATABASETestBackup01SETPARTNER='TCP://isrv04.xxx:50221';

2. Tasks -> Mirror ->Mirroring -> Config Security

Solutions:

RESTORE DATABASE @dbname FROM DISK = @backupfile WITH FILE = 1, NORECOVERY, NOUNLOAD;
RESTORE LOG @dbname FROM DISK = @backupfile WITH FILE = 2, NORECOVERY, NOUNLOAD;

These did the trick for me. I generated the commands through the "Script"-menu within the "Restore Database"-dialog of the Management Studio, because enabling mirroring was no problem when I restored through the "Restore Database"-dialog. My manually written
SQL-commands were missing the "NOUNLOAD" part.

版权声明:本文博客原创文章,博客,未经同意,不得转载。

最新文章

  1. Linux 等待进程结束 wait() 和 waitpid()
  2. 深入理解学习Git工作流
  3. linux开机启动服务和chkconfig使用方法(自定义服务路径启动)
  4. Linux下解压命令
  5. Android手机部分名词浅谈
  6. PHP 7 值得期待的新特性(下)
  7. php 数组指针相关函数current(),next(),prev(),end()
  8. Json格式的http请求
  9. myEclipse笔记(1):优化配置
  10. C# DES 加密解密
  11. CodeIgniter Apacheserver htaccess SEO重写写法
  12. PWM
  13. SQL连接操作
  14. oracle实用基础
  15. MFC:定时器
  16. python反射和面向对象的知识并简述基本的异常
  17. Visual C++没事别启用/Za编译选项
  18. JS的作用域链
  19. 【CF1009F】Dominant Indices(长链剖分)
  20. Cocos2dx Android工程的启动过程

热门文章

  1. 【Android进阶】Android面试题目整理与讲解(二)
  2. 191. Number of 1 Bits Leetcode Python
  3. R三星463无线网卡驱动,声音驱动程序,FN快捷键驱动,Easy_Display_Manager
  4. poj 3074 Sudoku(Dancing Links)
  5. MySQLHA系列MHA(一)
  6. HDU 1864最大报销额(一维背包)
  7. WP8.1开发者预览版本号已知 Bug
  8. Jedis连接
  9. FZU1669 Right-angled Triangle【毕达哥拉斯三元组】
  10. REQIMPORT-购买内部应用程序(R12.2.3)