SQL Server数据库锁定 [英] SQL Server Database Locked

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

问题描述

我试图删除SQL Server 2005中的现有数据库。我的第一次尝试产生以下错误:

I am trying to delete an existing database in SQL Server 2005. My first attempt produced the following error:


5030:数据库不能独占
锁定以执行操作。

5030: The database could not be exclusively locked to perform the operation.

我已经杀死了正在访问数据库的所有进程。我还删除了以前涉及到的复制订阅。

I have since killed all processes that are accessing the database. I have also removed the replication subscription that it had previously been involved in.

除了SQL Server进程和复制,还有什么可以持有锁的任何想法?

Any thoughts on what else that could be holding the lock on it besides SQL Server processes and replication?

更新:我重新启动了服务器,并修复了它。我试图避免,因为这是一个生产服务器,但嘿,你能做什么?

Update: I restarted the server, and that fixed it. I was trying to avoid that, since this is a production server, but hey what can you do?

推荐答案

我讨厌说它,但一个快速的解决方案是重新启动系统,确保sql server服务器服务没有启动,那么你应该能够删除。

I hate to say it, but a quick solution is to restart the system, make sure the sql server server service is not started, then you should be able to delete.

此外,是IIS如果您的数据库连接到web ap?

Also, is IIS stopped if you db is connected to a web ap?

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

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