Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
atomz4peace
Starting Member
7 Posts |
Posted - 2010-08-13 : 13:30:53
|
I have a full backup from a DB that has a 40 GB transaction log. The actual DB backup file is only 65MB. When I go to restore, it fails since I only have 9GB free disk space. Is there a way to restore from this backup file but tell sql server to not restore the log files, or to truncate on restore? I know I can re-do the backup as simple or truncate before backing up, but can I do anything with the backup I have now? This is non-production data, just for qa/test.Thanks! |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2010-08-13 : 13:41:23
|
That isn't possible.Instead you'll need to fix the source system. It isn't as easy as just truncating it as the file size will still be 40GB. To fix the source system, you'll need to either change your recovery model to SIMPLE or start backing up your transaction log frequently such as every 15 minutes. Once you've done either of these, you'll then need to shrink the transaction log file via DBCC SHRINKFILE.Tara KizerMicrosoft MVP for Windows Server System - SQL Serverhttp://weblogs.sqlteam.com/tarad/Subscribe to my blog |
 |
|
Kristen
Test
22859 Posts |
Posted - 2010-08-13 : 13:59:51
|
RESTORE will create a database the same size as the original (whether or not it is full, or the backup is large, or small, relative to the original database size).Only way around it is to reduce the size of the source database, and take a fresh backup .But if that is a production system then it should not be shrunk without good reason!However, if the production system is 65MB database with 40GB Log then someone, somewhere, has not brought it under control! or has overlooked / not spotted that the log has done "run-away growth" !As Tara said, just saying it a bit different in case it fills in any gaps. |
 |
|
|
|
|
|
|