Search code examples
deploymentssasaccess-deniedsql-server-2012sql-server-data-tools

SQL Server 2012 - SSAS Deployment Failed: File System Error, Access is Denied


The context is OLAP cube development. After configuring my project though SQL Server Data Tools (SSDT, the new BIDS) I am unable to deploy the project.

Every time the deployment process is started I get an error like the one below:

File system error: The following error occurred while opening the file '\\?\D:\[...]\database\mssql\tmpdb\MDTempStore_1864_9_no8wd.tmp': Access is denied.

(The [...] denotes some part of the path I ommited for brievty)

I always get the same error, indicating that some .tmp file could not be accessed.

My environment:

  • OS: Windows Server 2008 R2 Standard, SP1
  • SQL Server: SQL Server 2012 (v11.0.2100.60), running on localhost

What I tried:

  • I have the File System access rights for the folder in question (at some point I even tried with Admin privileges on the machine, didn't help)
  • I tried to deactivate the anti-virus in case it was performing on-access-scan (still didn't help)
  • Attempts to deploy/process individual dimensions causes the same problem
  • Deploying dimensions or cubes programmatically through SMO (instead of SSDT) runs into the same problem
  • Deploying DataSource objects as well as DataSourceView objects works fine

Maybe some of you faced similiar issues or have further suggestions/ideas?

Thanks for you help!


Solution

  • So, I finally figured it out.

    As expected it was a permission issue, but despite the error message hinting at some missing file system permissions, the cause of the problem was the user I configured the Data Source with.

    The SQL User I specified was given the roles

    • db_datareader
    • db_datawriter
    • db_ddladmin

    on the source database but this doesn't seem to be enough. When I tried to give him the server role sysadmin it started working.

    This is probably overkill, one could further fine-tune the role assignment but for now it also works that way.