Link to home
Start Free TrialLog in
Avatar of pg_india
pg_india

asked on

SHRINK DATA FILE(mdf and log files)

I am shrinking the temp_db file from 30GB. I want to know what effect it can make to my performance. Bascally i need to know why temp_db is used and  why so much space was alloctated to it initalliy. Some ex-dba has done that.

Avatar of arbert
arbert

Temp_Db is used whenever temporary tables are created or whenever someone does large sorts.  Everytime you restart SQL Server tempdb is recreated, but it doesn't hurt to shrink it once in a while if you don't restart the server that often.

Of course, any time you shrink ANY database, it does have an affect on the server because of the extra IO that's involved.

Brett
TempDB database size is usually set base on how much space is needed for processing using temporary table. it seems that your setting is too big. you can decrease your tempdb database from SHRINK database option and set file growth to 10% for tempdb database setting
Avatar of pg_india

ASKER

Thanks you all for your views and experts comments.

I want to know what effect it can make to my performance???
Now that temporary tables are used to store in temp_db shrinking it will make it slower? I mean suppose i have shrinked it After shriking it will reduce the speed of temp_db file??


ASKER CERTIFIED SOLUTION
Avatar of arbert
arbert

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial