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

ALTER  DATABASE tempdb

MODIFY FILE(name='tempdev', filename='D:\tempdb.mdf') ;

 

GO

 

ALTER  DATABASE tempdb

MODIFY FILE(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.

2015-05-27 ;11:56:45.94 spid9s      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:45.94 spid9s      Error: 5120, Severity: 16, State: 101.

2015-05-27 ;11:56:45.94 spid9s      Unable to open the physical file "D:\tempdb.mdf". Operating system error 2: "2(The system cannot find the file specified.)".

2015-05-27 ;11:56:45.94 spid9s      Error: 1802, Severity: 16, State: 4.

2015-05-27 ;11:56:45.94 spid9s      CREATE DATABASE failed. Some file names listed could not be created. Check related errors.

2015-05-27 ;11:56:45.94 spid9s      Could not create tempdb. You may not have enough disk space available. Free additional disk space by deleting other files on the tempdb drive and then restart SQL Server. Check for additional errors in the event log that may indicate why the tempdb files could not be initialized.

2015-05-27 ;11:56:45.94 spid9s      SQL Trace was stopped due to server shutdown. Trace ID = '1'. This is an informational message only; no user action is required.

2015-05-27 ;11:56:46.20 spid16s     The SQL Server Network Interface library could not deregister the Service Principal Name (SPN) [ MSSQLSvc/xxxx.xxxx.xxxx.com ] for the SQL Server service. Error: 0x2af9, state: 61. Administrator should deregister this SPN manually to avoid client authentication errors.

2015-05-27 11:56:46.20 spid16s     The SQL Server Network Interface library could not deregister the Service Principal Name (SPN) [ MSSQLSvc/xxxx.xxx.xxxx.com:1433 ] for the SQL Server service. Error: 0x2af9, state: 61. Administrator should deregister this SPN manually to avoid client authentication errors.


我猜测是系统权限问题导致,于是我右键单击D盘的属性选项,在”Security“里面找到Users(xxxx\Users),授予用户”Full Control“权限,然后重启数据库实例,问题解决。我后面测试了一下,其实在Windows Server 2012下,将任何数据库文件放置在磁盘根目录下都有这个权限问题.

Unable to open the physical file xxxx. Operating system error 2的更多相关文章

  1. CREATE FILE encountered operating system error 5(Access is denied.)

    这篇博文主要演示"CREATE FILE encountered operating system error 5(Access is denied.)"错误如出现的原因(当然只是 ...

  2. InnoDB: Operating system error number 87 in a file operation. 错误87的解决方法

    InnoDB: Operating system error number 87 in a file operation. 错误87的解决方法 140628  8:10:48 [Note] Plugi ...

  3. mysql数据库报错:InnoDB: Operating system error number 13 in a file operation

    环境:centos6.5 x86_64 启动mysql发现日志报错(日志路径可以查看/etc/my.cnf的配置) 160722 10:34:08 [Note] Found 42570716 of 4 ...

  4. DBCC CHECKDB 遭遇Operating system error 112(failed to retrieve text for this error. Reason: 15105) encountered

    我们一个SQL Server服务器在执行YourSQLDBa的作业YourSQLDba_FullBackups_And_Maintenance时遇到了错误: Exec YourSQLDba.Maint ...

  5. Error: 17053 LogWriter: Operating system error 21(The device is not ready.)

    今天在Detach数据库的时候出现错误,运行DBCC CHECKDB从SQL Server error log中看到下面的信息: Error: 17053, Severity: 16, State: ...

  6. LogWriter: Operating system error 21(error not found) encountered

      一台老旧的数据库服务器(SQL Server 2005)突然报如下错误,而且数据库处于RECOVERY PENDING ,检查错误日志,发现这个错误是突然出现的.没有任何其它人为误操作导致 Dat ...

  7. 如何定位“Operating system error 32(failed to retrieve text for this error. Reason: 15105)”错误中被占用的文件

      之前在这篇"Operating system error 32(failed to retrieve text for this error. Reason: 15105)"博 ...

  8. Operating system error 32(failed to retrieve text for this error. Reason: 15105)

    一台数据库服务器的事务日志备份作业偶尔会出现几次备份失败的情况,具体的错误信息为: DATE/TIME:    2018/7/30 12:10:52 DESCRIPTION: BackupDiskFi ...

  9. AdventureWorksDW2008R2 attach: Unable to open the physical file. Operating system error 5: "5(Access is denied.)

    http://stackoverflow.com/questions/26014133/adventureworksdw2008r2-attach-unable-to-open-the-physica ...

随机推荐

  1. RMAN Catalog创建、配置和管理

    环境:RHEL6.4 + Oracle 11.2.0.4 一.创建数据库catdb 1.1 官档的建库脚本示例 1.2 根据我实际环境修改如下项 1.3 创建必要目录并赋予权限 1.4 执行脚本建库 ...

  2. RAC某节点启动遭遇ORA-01105,ORA-01606

    环境:RHEL6.5 + Oracle11.2.0.4 双节点RAC 故障现象:节点1实例没有启动成功,节点2正常启动. 1.故障现象 2.解决过程 3.总结 1.故障现象 尝试启动RAC 节点1,遭 ...

  3. 利用GeoWebCache实现WebGIS地形图展示的缓存优化

    文章版权由作者李晓晖和博客园共有,若转载请于明显处标明出处:http://www.cnblogs.com/naaoveGIS/. 1.前言 在WebGIS中,影像金字塔是一个很重要的概念.在WebGI ...

  4. DotNet项目中的一些常用验证操作

    在项目中需要对用户输入的信息,以及一些方法生成的结果进行验证,一般在项目中较多的采用js插件或js来进行有关信息的校验,但是从项目安全性的角度进行考虑,可对系统进行js注入. 如果在后台对用户输入的信 ...

  5. idea 自动提示生成 serialVersionUID

    from: http://tonycody.blog.51cto.com/8421818/1401422 Intellij IDEA 默认没启用这个功能. Setting->Inspection ...

  6. Sql Server之数据类型详解

      数据类型是一种属性,用于指定对象可保存的数据的类型,SQL Server中支持多种数据类型,包括字符类型.数值类型以及日期类型等.数据类型相当于一个容器,容器的大小决定了装的东西的多少,将数据分为 ...

  7. Windows Phone 如何在程序中播放提示声音?

    在Windows Phone 中播放提示音可以使用 Microsoft.Xna.Framework.Audio 命名空间下的 SoundEffect 类.具体使用方法如下: 1. 根据声音文件路径创建 ...

  8. 我理解的this

    this指的就是当前上下文环境对象,主要分两种情况. 1.函数中的this指的是调用该函数的那个上下文环境对象 这个的理解还是非常重要的. 看一个全局函数的例子 var b = 1; function ...

  9. 你必须知道ASP.NET知识------关于动态注册httpmodule(对不起汤姆大叔)

    一.关于动态注册的问题 很多人看过汤姆大叔的MVC之前的那点事儿系列(6):动态注册HttpModule ,其实汤姆大叔没有发现httpmodule动态注册的根本机制在哪里. 亦即:怎么动态注册?为什 ...

  10. 十大经典排序算法总结(JavaScript描述)

    前言 读者自行尝试可以想看源码戳这,博主在github建了个库,读者可以Clone下来本地尝试.此博文配合源码体验更棒哦~~~ 个人博客:Damonare的个人博客 原文地址:十大经典算法总结 这世界 ...