Tuesday, April 23, 2013

SharePoint Config database Log file too big – reduce it!

Today, I wanted to refresh a content database in test environment from production environment.

In test environment, I see the d drive is almost full. Out of 200 GB, only 8 GB was left out.

There were 10 web applications and many service applications were configured in test environment.

I checked the SQL Server and found that transaction log file sizes became huge.

For SharePoint config database log, I see the transaction log file size as 36 GB.

Due to lack of space, I was not able to restore my content db from prod.

I started focusing on shrinking the transaction log files.

We need to ensure that transaction log file backup are taken before we start shrinking. As it is test environment, we don't need to worry about backup as it contains test data.

I was able to shrink all transaction log files for all the config databases and able to get around 60 GB free space.

Note: We can perform shrinking on databases or individual database files (.mdf & .ldf).

Reference article about how to shrink database or files

No comments: