Tag Archives: MSSQL

Checking recovery models in MS SQL Server

We have quite a few databases that have been added to our SQL environment by 3rd parties. The default recovery model is “Full”, yet a lot of the databases have no scheduled transaction log backups. What does this mean?

Well, a database with “Full” recovery model will never reclaim space in LDF files unless a transaction log backup is run. A full database backup isn’t enough.

So the options here are: set recovery model to simple, or make sure you have backup jobs in place to empty your log files periodically.

Here’s how to list all your databases and their associated recovery models:

SELECT name AS [Database Name],
recovery_model_desc AS [Recovery Model]
FROM sys.databases
GO

Advertisements