When administering a SharePoint farm, you’re bound to have a situation come up where you’re low on diskspace for a site with increasing content. You may want to move a content database to another drive on your SQL server in order to gain some free space back. Fortunately, this isn’t too hard to accomplish using the following steps and should work in SharePoint 2010 or 2013:
1. Quiesce the Farm – This stops people from being able to make changes to your system while you are working on it. To quiesce SharePoint 2010, use stsadm: stsadm -o quiescefarm -maxduration n
2. Backup any database that you are moving
3. Turn off SharePoint Services to unlock the databases You can either stop the services through the Central Administration or you can do it in the Services Console. To stop the connections to the existing databases, stop the following services: Office SharePoint Search Service Windows SharePoint Services Administration Windows SharePoint Services Search Windows SharePoint Services Timer Windows SharePoint Services Tracing World Wide Web Publishing Service
4. After the services are stopped, detach the database(s) that you are looking to move.
5. After detaching the database(s), copy them to your new location.
6. Reattach your database(s)
7. Restart the services
8. Unquiesce the farm: To unquiesce SharePoint 2010, use stsadm: stsadm -o unquiescefarm
* Some of this content is sourced from Microsoft Technet