Advertisements
HEADLINES

How to Shrink database logs when databases are in availability group

One of my customers reported an issue, saying, log disk drive was almost full. When I checked, there are no jobs configured in SQL to shrink log files and databases are in the availability group. I had executed below mentioned steps to free up space on the log disk drive.

Since databases are in the high availability group and database recovery model is set as full, so I am unable to shrink complete log file size even specifying shrink file to 100MB. Anyhow, I got half of the free space on the drive, that helped me in resolving the application stop issue.

  1. Open SQL Server Management Studio (Run >> SSMS)
  2. Right click on the database >> Tasks >> Shrink >> FileTECHNOGUNS.com+shrink+log+avilability1
  3. In Shrink File form (See below screen):
  • Change File Type to Log
  • In the same form select Reorganize pages before releasing unused space, provide shrink log file size in MB’s and click ’Ok’.TECHNOGUNS.com+shrink+log+avilability2

If you have any questions/suggestions, please do comments below or write to me.
“Yours, Ravi Theja Madisetty”

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s