Surendra Sharma

Surendra Sharma

Search This Blog

Monday, August 15, 2016

Getting new name of blog on 15 Aug 2016 - www.sitecorelessons.com




Independence Day greetings to you all. Today is 15th August 2016 and I am celebrating 70th Independence Day of my greattttt country India.

On this great day, I am happy to announce that my blog is getting new name http://www.sitecorelessons.com

http://surendrasharmadotnet.blogspot.com blog started on May 4, 2010. Since that day I have blogged nearly 250 blog posts and have witnessed over 100 thousand views on this blog. 

This blog was started as a learning lessons collection of personal experienced code and slowly it turned out to be a place for the coder enthusiast to talk Sitecore, .NET and SQL.

I really want to thank everyone for your kind support.

Monday, August 8, 2016

How to bring database from recovery mode to normal mode



I have published my last article about database restore. This article is also related with database.

I was trying to restore my Sitecore database from script, but that database was in recovery mode. If you try to restore any database which is in recovery mode, you will get sql error

Msg 3101, Level 16, State 1, Line 2
Exclusive access could not be obtained because the database is in use.
RESTORE DATABASE is terminating abnormally.

How to change any database mode from recovery to normal?

Solution:

There may be scripts and other option related with this but I suppose below is pretty straight forward way.

To remove recovery mode 

1. You need to offline database by Right click on Database -> Tasks -> Take Offline as 





2. Bring database to online by Right click on Database -> Tasks -> Bring Online as


 

Please leave your comments or share this trick if it’s useful for you.