Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12

Faster way to release the Unused Space back to Disk Expand / Collapse
Author
Message
Posted Tuesday, December 18, 2012 9:50 AM
Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: 2 days ago @ 3:23 PM
Points: 557, Visits: 1,637
This is the second time? If you shrink a database at all, it should be one-off job following a one-off large data deletion. If it grows "too large" again, then the DB needs extra space for its operations.

One thing to look at is if the autogrow settings are too large. If you have a 5GB DB set to grow 5GB at a time and it results in 48% free space, then you might want to shrink again (to a size that that includes a more reasonable amount of free space), then set the autogrowth smaller to a setting that allows for growth but makes growths unlikely to happen very often.
Post #1397892
Posted Friday, December 21, 2012 1:29 AM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Sunday, September 14, 2014 1:28 AM
Points: 219, Visits: 693
I have done the things that you have suggested but still in the next ETL run, again the Datafile size is boosted up and used space by the file is way less.

Can you please suggest. What can be done now..
Post #1399257
Posted Friday, December 21, 2012 1:33 AM


SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: 2 days ago @ 9:39 AM
Points: 882, Visits: 4,129
why dont you change your recovery model to "bulk logged" while your ETLs are scheduled?

----------
Ashish
Post #1399260
Posted Friday, December 21, 2012 1:34 AM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Yesterday @ 2:35 PM
Points: 40,438, Visits: 36,895
Mac1986 (12/21/2012)
I have done the things that you have suggested but still in the next ETL run, again the Datafile size is boosted up and used space by the file is way less.

Can you please suggest. What can be done now..


If the space in the data file is used up and the file grows during ETL, then leave the data file alone, it needs to be the size it is.



Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1399262
Posted Friday, December 21, 2012 1:35 AM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Yesterday @ 2:35 PM
Points: 40,438, Visits: 36,895
crazy4sql (12/21/2012)
why dont you change your recovery model to "bulk logged" while your ETLs are scheduled?


Not going to affect the size or usage of the data file in any way.



Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1399263
Posted Friday, December 21, 2012 1:37 AM


SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: 2 days ago @ 9:39 AM
Points: 882, Visits: 4,129

Not going to affect the size or usage of the data file in any way.


sorry for my Friday hangover, I thought the complain is about log file :)


----------
Ashish
Post #1399266
Posted Wednesday, January 2, 2013 3:53 PM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Sunday, September 14, 2014 1:28 AM
Points: 219, Visits: 693
I have 2 quick questions on Data file size usage behavior

1) I see that Indexes have heavy fragmentation levels: This effects the DML Performance for sure, but will this allow the data file size to grow extra than actual consumed space?

2) Will adding few indexes at appropriate places reduce the Data file to not pre capture so much disk space than actual consumed space.?


Post #1402112
Posted Thursday, January 3, 2013 2:54 AM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Wednesday, November 19, 2014 5:03 AM
Points: 2,840, Visits: 3,975
Mac1986 (1/2/2013)
1) I see that Indexes have heavy fragmentation levels: This effects the DML Performance for sure, but will this allow the data file size to grow extra than actual consumed space?

NO there is no 'extra' or 'actual consumed' kind of thing in index fragmentation level. framentation happens due to page split whch is dependent on fill factor.

Mac1986 (1/2/2013)
(2) Will adding few indexes at appropriate places reduce the Data file to not pre capture so much disk space than actual consumed space.?
NO. index addition always cost you space/disk and it helps you to retrieve the data faster but slow down your DML operation

for more details see this link http://blogs.msdn.com/b/pamitt/archive/2010/12/23/notes-sql-server-index-fragmentation-types-and-solutions.aspx


-------Bhuvnesh----------
I work only to learn Sql Server...though my company pays me for getting their stuff done
Post #1402259
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse