web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Dynamics 365 Community / Blogs / Dynamics 365 Vs Me / Restore the DB, showing DB ...

Restore the DB, showing DB in use

Deepak Agarwal Profile Picture Deepak Agarwal 8,602

Hi Folks,

Recently I was facing some issue while restoring AX database, whenever i try to restore the Transactional DB its show error "DB is use" while actually this DB is not used anywhere. Than I try to take take the database offline, But again there was one other issue.

Same issue again DB offline taking very long time.

I tried below steps and this worked for me. :)

Step 1: Try to run below two queries in same given sequence.

i. ALTER DATABASE <DBNAME> SET OFFLINE WITH ROLLBACK IMMEDIATE

ii. ALTER DATABASE <DBNAME> SET Offline

Step 2: Now try to take offline manually.

clip_image001

Step 3: Restore the DB.

Step 4: Some time after doing restoration/backup DB will not work.

Than u need to roll back above query operation

ALTER DATABASE <DBNAME> SET online WITH ROLLBACK IMMEDIATE

ALTER DATABASE <DBNAME> SET online.

Related Post:

AX DB restoration: Database goes into “Restoring” state for long

-Harry


This was originally posted here.

Comments

*This post is locked for comments