Wednesday, March 21, 2012

Move tempdb from T: to G:

How do I move the tempdb file from T: to G: drive?
Thank You,
StevenUse ALTER DATABASE. See Books Online for syntax.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Steven" <anonymous@.discussions.microsoft.com> wrote in message
news:153201c3aea4$d218b510$a601280a@.phx.gbl...
> How do I move the tempdb file from T: to G: drive?
> Thank You,
> Steven|||Hi,
Please use the below steps:
How to Move TEMPDB from one location to another
---
USE master
go
ALTER DATABASE tempdb MODIFY FILE (NAME = tempdev, FILENAME ='G:\mssql\data\tempdb.mdf')
go
ALTER DATABASE tempdb MODIFY FILE (NAME = templog, FILENAME ='G::\mssql\log\templog.ldf')
go
where NAME refers to the logical name of the tempdb database and
log files, and where FILENAME refers to the new location of the
tempdb files. Once this command has run, you must restart the
mssqlserver service before it takes affect.
This steps are common for SQL Server 7.0 and 2000.
Thanks
Hari
MCDBA
"Tibor Karaszi" <tibor.please_reply_to_public_forum.karaszi@.cornerstone.se>
wrote in message news:eUeOrUqrDHA.2340@.TK2MSFTNGP12.phx.gbl...
> Use ALTER DATABASE. See Books Online for syntax.
> --
> Tibor Karaszi, SQL Server MVP
> Archive at:
http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
>
> "Steven" <anonymous@.discussions.microsoft.com> wrote in message
> news:153201c3aea4$d218b510$a601280a@.phx.gbl...
> >
> > How do I move the tempdb file from T: to G: drive?
> >
> > Thank You,
> >
> > Steven
>

No comments:

Post a Comment