Moving SQL Databases to Another Drive

by Anton 11. December 2013 15:46

Since the space on my SSD was getting scarce, I decided to transfer the database files to a different drive. It was much easier than I expected:

  1. Detach the DB (via ‘Tasks’)
  2. Move the mdf and ldf files to the new location. (They are usually located somewhere under ‘C:\Program Files\Microsoft SQL Server\’.)
  3. Attach the DB by choosing the mdf file.

Thanks to the instructions from katieandemil. They were especially appropriate since I also had SQL Server 2008 R2 installed.

If you rather like to use Transact-SQL follow this stackoverflow post.

Tags:

Administration | Database

About the author

The authors are the admins at teamaton.

Isn't everyone a little admin?

Month List

Page List