March 17, 2011 at 2:15 am
Hi All,
I'm new to sql and have a 2008db
the db datafile is 108gb in size with no space free
The developers decided to dispose of a redundant table and once that is deleted the db becomes 108gb with 68gb free.
I then need to recover the space from the drive
If I try to do a shrink datafile on the server then it takes 2 days and then some to complete and generates a huge log file
I have to restore the db to a new server, and so is there any way I can restore the db and recover the space..or after a restore will it change where the data is stored in the file to make the shrink faster
March 17, 2011 at 3:14 am
you can try to move the big tables and indexes in different filegroup.
----------
Ashish
March 17, 2011 at 3:19 am
you have more accurate answer here :-
http://www.sqlservercentral.com/questions/Administration/67277/
----------
Ashish
March 17, 2011 at 6:12 am
Restoring the database will recreate it with the same size and allocation you have now.
108gb is not that big a database. In fact, it's almost a small database. If it's taking 2 days to shrink 60gb, it's likely that it's because of contention on the resources. If you have to shrink it online while users are active in the database, shrink it in smaller chunks. Or, you could plan for a downtime on a weekend, kick all the users off and then shrink it.
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply