• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1443
  • Last Modified:

SQL can't create files on drive d or e

Hello,

When trying to create a database on our new SQL server ( with drive d set for data and e for log files ) I get the following message:

CREATE FILE encountered operating system error 5(failed to retrieve text for this error. Reason: 15105) while attempting to open or create the physical file 'D:\SQLDatabases\test.mdf'.
CREATE DATABASE failed. Some file names listed could not be created. Check related errors. (Microsoft SQL Server, Error: 5123)

Outside of SQL we can create files in the relevant folders. It makes no difference if I login using windows or SQL authentication.  Also when trying to restore files from d or e SQL does not show the files in the browse window.

Thanks




0
Petermcg001
Asked:
Petermcg001
  • 2
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
if this is a cluster node, D: and E: must be on the same cluster resource ..
if not, still, D: and E: must not be mapped (network) drives.

please clarify
0
 
Raja Jegan RSQL Server DBA & ArchitectCommented:
>> Outside of SQL we can create files in the relevant folders. It makes no difference if I login using windows or SQL authentication.

Check whether the startup account of SQL Server has permissions on D: drive in order to create database with files on D: drive..
Also check whether it is a mapped network drive as mentioned above..
0
 
Petermcg001Author Commented:
Hi,

It was the account issue, it had been set to use the network service.  I changed it to local system and it's fine now.

It's interesting that the account had access to c but not d or e.

Thanks for your help.
0
 
Raja Jegan RSQL Server DBA & ArchitectCommented:
Welcome..
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now