尝试还原数据库时不可见bak文件 [英] bak file not visible when trying to restore database

查看:282
本文介绍了尝试还原数据库时不可见bak文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Visual Studio上运行经典的ASP项目,因此我试图还原数据库.尝试还原.bak文件时似乎找不到.在C盘中看不到它.我查了一下,发现它与权限有关.我已尝试在将.bak文件的properties>安全性设置为'Everyone'之后启用权限,但此方法不起作用.我也尝试过NT Service\MSSQLSERVER.请参阅以下内容.

I am trying to run a classic asp project on visual studio and therefore I am trying to restore a database. I cannot seem to find the .bak file when trying to restore it. It wasn't visible in the C-drive. I have looked it up and have seen that it has something to do with permissions. I have tried enabling permissions after properties>security of .bak file to 'Everyone', it did not work. I have also tried NT Service\MSSQLSERVER. Please see the following below.

推荐答案

您还必须启用对文件所在文件夹的权限. SSMS首先需要浏览文件夹,然后读取文件.

You also have to enable permissions to the folder where the file is located. SSMS first needs to browse the folder, then to read the file.

在您的情况下,SQL Server尝试使用NT Service\MSSQLSERVER帐户访问该文件夹,因此应授予该帐户权限,而无需(向所有人)授予更多权限.

In your case, SQL server tries to access the folder using NT Service\MSSQLSERVER account, so permissions should be granted to that account, no need to give more permissions (to everyone).

如果上述方法仍无济于事,请尝试以下方法:

Also try below if above doesn't help:

  • 关闭/打开SSMS
  • 将文件从根目录移到某个文件夹并授予该文件夹的权限
  • 使用TSQL脚本而不是SSMS还原数据库

这篇关于尝试还原数据库时不可见bak文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆