SSRS – Moving Report Server Databases to Another Drive

ssrs

Currently our Reporting Server Databases are in C:
So would like to place them in E:\RS\

Can I know how can I move the ReportServer and ReportServerTempDB Database files from one location to another and things I should keep in mind before this operation.

Best Answer

There will be minimal downtime, so plan this in a maintenance window:

Don't use detach/attach!

  1. Have verified backups!
  2. Use Alter database...modify file... (do below for mdf and ldf files)

    use master;
    alter database dbname 
    modify file (
        name = 'logicalName', 
        filename = 'E:\RS\db_name.mdf'); --> This is the new file location 
    
  3. Now offline the database:

    alter database db_name set offline with rollback immediate;
    
  4. Physically copy the mdf and ldf files to the new location.

  5. Bring the database online:

    alter database db_name set online;
    

If you script out and test out on a dummy database, you will see how much time it takes and will build your confidence.