Nov9

Kill database connections to SharePoint  

Categories: SharePoint Administration

There will be occasions where you need to work with the databases for SharePoint in SQL Server Management Studio.  Backups, restores, etc... If you run into problems with there being existing connections to the databases preventing you from performing maintenance items, here’s a way to kill those database connections.

Management > Activity Monitor > View Processes

 image

You’ll then have a list of all connections to the SQL Server.  Sort the list so that the connections to the specific database you are working on are grouped together.  Right-Click on a process, and select Kill Process

image

Once all of those processes (and connection with it) are killed, you’ll be able to perform those maintenance items.

 
Share It:          
 
 

Comments

Robin  commented on  Friday, November 13, 2009  7:02 AM 

How about just marking the contentdatabase as offline in CA?

Dan  commented on  Sunday, November 15, 2009  3:35 AM 

Robin! Hope the Netherlands are treating you well. Yup, that would work as well.

This is something I usually do when working on a dev server and need to 'do my thing' while I'm already in SQL Studio. You know how lazy us americans are. ;)

Robin  commented on  Wednesday, December 02, 2009  1:43 PM 

Yes! Well.. another option is to 'detach' the database or mark the database as single-user and read-only to kill all the running connections ;)

But I assumed that you, as a lazy american, would just go into CA and mark the database as offline.. less clicks there buddy!

Guess I need to work on my american way of thinking..

Leave a comment





CAPTCHA Image Validation