首页 > 开发 > 综合 > 正文

Unable to open the physical file xxxx. Operating system error 2

2024-07-21 02:46:56
字体:
来源:转载
供稿:网友
Unable to open the physical file xxxx. Operating system error 2 2015-05-27 17:19 by 潇湘隐者, ... 阅读, ... 评论, 收藏, 编辑

在新UAT服务器上,需要将tempdb放置在SSD(固态硬盘)上。由于SSD(固态硬盘)特性,所以tempdb的文件只能放置在D盘下面,而不能是D盘下的某一个目录下面。

ALTER DATABASE tempdb
MODIFYFILE(name='tempdev', filename='D:/tempdb.mdf') ;
GO
ALTER DATABASE tempdb
MODIFYFILE(name='templog', filename='D:/templog.ldf') ;
GO

修改了tempdb的目录后,重启数据库服务,结果出现错误信息:“FCB::Open failed: Could not open file D:/tempdb.mdf for file number 1. OS error: 2(The system cannot find the file specified.)" ,具体错误信息如下所示:

2015-05-27 ;11:56:44.88 spid9s The resource database build version is 12.00.2000. This is an informational message only. No user action is required.
2015-05-27 ;11:56:45.49 spid9s Starting up database 'model'.
2015-05-27 ;11:56:45.67 Server The SQL Server Network Interface library successfully registered the Service PRincipal Name (SPN) [ MSSQLSvc/GEK-MIS01UAT.gfg1.esquel.com ] for the SQL Server service.
2015-05-27 ;11:56:45.67 Server The SQL Server Network Interface library successfully registered the Service Principal Name (SPN) [ MSSQLSvc/GEK-MIS01UAT.gfg1.esquel.com:1433 ] for the SQL Server service.
2015-05-27 ;11:56:45.83 spid9s Clearing tempdb database.
2015-05-27 ;11:56:45.84 spid9s Error: 5123, Severity: 16, State: 1.
2015-05-27 ;11:56:45.84 spid9s CREATE FILE encountered operating system error 5(access is denied.) while attempting to open or create the physical file 'D:/tempdb.mdf'.
2015-05-27 ;11:56:45.94 spid9s Error: 17204, Severity: 16, State: 1.
上一篇:排列组合的实现

下一篇:SQL必备知识点

发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表