April 3, 2018 at 6:36 am
Good day,
I have a DB which is 850 GB in size and when i take a full backup the backup size is 160 GB.On the DB properties its showing 9GB space available.
Any idea why this big difference in size.
Thanks
T
April 3, 2018 at 6:44 am
tmmutsetse - Tuesday, April 3, 2018 6:36 AMGood day,
I have a DB which is 850 GB in size and when i take a full backup the backup size is 160 GB.On the DB properties its showing 9GB space available.
Any idea why this big difference in size.Thanks
T
Thats the free space available in your database which will be used for later growth. The backup size seems fine.
April 3, 2018 at 6:53 am
Is the backup compressed?
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
April 3, 2018 at 9:08 am
@Gila The backup is on the default server setting
April 3, 2018 at 9:13 am
@ VastSQL - You mean its normal 850 GB mdf to 160 GB. bak difference?
April 3, 2018 at 9:14 am
Whats the output of this code snippet?
select value_in_use from sys.configurations where name = 'backup compression default'
If it's 1 the default setting is to compress and that would correlate with the backup size your seeing.
You could also query msdb.dbo.backupset and check the backup_size vs the compressed_backup_size
April 3, 2018 at 9:16 am
tmmutsetse - Tuesday, April 3, 2018 9:08 AM@Gila The backup is on the default server setting
If you run the following query:
exec sp_configure 'backup compression default';
What is the "config_value"?
If it's set to 1, then the server by default will try to compress your backups.
April 3, 2018 at 9:42 am
tmmutsetse - Tuesday, April 3, 2018 9:08 AM@Gila The backup is on the default server setting
And is the server default to compress backups?
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
April 4, 2018 at 5:35 am
tmmutsetse - Tuesday, April 3, 2018 9:13 AM@ VastSQL - You mean its normal 850 GB mdf to 160 GB. bak difference?
What kind of data it holds ? Is the data getting loaded by bulk operation?
I have a db with 48GB , 5GB backup with 380 MB freespace
April 4, 2018 at 5:47 am
Yes the data is loaded in bulk through RabbitMQ
April 4, 2018 at 5:54 am
tmmutsetse - Wednesday, April 4, 2018 3:17 AM@Gila the server is ticked to compress backup on server properties.
There you go then. The backup is compressed, and hence is a lot smaller than the data size of the database.
It's not related to how you load the data, it's simply that the backup is being compressed.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
April 4, 2018 at 5:59 am
Hi,
try this query to check your backup-compression-ratio:
SELECT
[database_name],
[backup_size],
[compressed_backup_size],
[backup_finish_date],
CAST(backup_size/compressed_backup_size AS DECIMAL(16,2)) AS backup_compression_ratio
FROM msdb..backupset;
It depends on the data, but the compression ratio could be big.
Kind regards,
Andreas
Viewing 13 posts - 1 through 12 (of 12 total)
You must be logged in to reply to this topic. Login to reply