Wednesday, July 11, 2012

Move tempdb to another hard drive

USE master
GO

alter database tempdb modify file(name='tempdev',filename='E:\Database\tempdb\tempdb.mdf')
go
alter database tempdb modify file(name='templog',filename='E:\Database\tempdb\templog.ldf')
go
Restart sql server to make the change, and delete old files.

No comments: