数据库处于恢复模式 [英] Database in recovery mode

查看:215
本文介绍了数据库处于恢复模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用sql server 2008中的特定软件包执行数据库迁移。

但是软件包被卡住了所以我杀了软件包甚至重新启动了服务器。

重新启动软件包后,数据库现在处于恢复模式(简单)。

如何使用以前的所有数据将数据库恢复到非恢复模式

在杀死软件包之前。

解决方案

如果在运行一些繁重的操作时sqlserver进程被终止,数据库通常会进入InRecovery模式。这是一个自动恢复过程。一段时间后数据库进入正常模式。但是,您可以通过运行以下语句来查看自动恢复过程的进度。

  SELECT  sqltext。  TEXT 
req.session_id,
req.status,
req.command,
req.cpu_time,
req.total_elapsed_time,
req.percent_complete
FROM sys.dm_exec_requests req
CROSS APPLY sys.dm_exec_sql_text(sql_handle) AS sqltext


I was performing a migration of datbase using a particular package in sql server 2008.
But the package was stuck so I killed the package and even restarted the server .
After restarting the package the database is now in the recovery mode(simple).
How do i bring the database back in the non recovery mode with all my previous data
before killing the package.

解决方案

If sqlserver process is killed while running some heavy operations, the database usually goes InRecovery mode. The is an auto recovery process. The database gets in normal mode after a while. However, you can see progress of the auto recovery proces by running the following statements.

SELECT sqltext.TEXT,
       req.session_id,
       req.status,
       req.command,
       req.cpu_time,
       req.total_elapsed_time,
       req.percent_complete
FROM   sys.dm_exec_requests req
       CROSS APPLY sys.dm_exec_sql_text(sql_handle) AS sqltext


这篇关于数据库处于恢复模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆