Friday, February 24, 2012

hot to shrink tempdb?

7 Gb has been allocated for my tempdb (data file) initially, only 800 Mb are
being used. Is there any way I can change my tempdb data file to ~1 Gb? I
can't shut down the system, this is not an option.
Thank you in advance for your help
Leon Shargorodsky--select * from tempdb.dbo.sysfiles
DBCC SHRINKFILE (<logicalfilename>,<mb>) -- datafile
DBCC SHRINKFILE (<logicalfilename>,<mb>) --logfile
sample:
DBCC SHRINKFILE (MSDBData,1000)
DBCC SHRINKFILE (MSDBLog,200)
"Leon Shargorodsky" wrote:
> 7 Gb has been allocated for my tempdb (data file) initially, only 800 Mb are
> being used. Is there any way I can change my tempdb data file to ~1 Gb? I
> can't shut down the system, this is not an option.
> Thank you in advance for your help
> Leon Shargorodsky|||http://www.aspfaq.com/2446
--
Please post DDL, sample data and desired results.
See http://www.aspfaq.com/5006 for info.
"Leon Shargorodsky" <LeonShargorodsky@.discussions.microsoft.com> wrote in
message news:88A36F06-8FF7-4483-9BDC-89F349E03BAD@.microsoft.com...
> 7 Gb has been allocated for my tempdb (data file) initially, only 800 Mb
are
> being used. Is there any way I can change my tempdb data file to ~1 Gb? I
> can't shut down the system, this is not an option.
> Thank you in advance for your help
> Leon Shargorodsky

No comments:

Post a Comment