1

I am using TFS build process with the following MSBuild arguments:

/p:DeployOnBuild=True /p:PublishProfile=Development

The publish profile works when run from my machine in VS, but when it is run from the build server, it fails with this error:

Unable to create directory "\\10.21.8.24\w$\Connector". Access to the path '\\10.21.8.24\w$\Connector' is denied.

This is a FileSystem publish.

I tried specifying the permissions for the user account that the TFSBuildServiceHost service runs as on the target machine. I've added full control on the entire W: drive, as well as I have created a share on the Connector folder and allowed the read & write access of this user to it.

Another thing I tried was stopping the web application in the IIS management console - but, the error still stays the same.

Bartosz
  • 4,406
  • 7
  • 41
  • 80

1 Answers1

1

First, you could double check the account permissions by manually RDC that machine and try to access this \\10.21.8.24\w$\Connector folder using your TFS build service account, ensure this folder can be found and accessed successfully.

Also make sure the Connector folder is writable not Read Only.


Update

w$ is a Admin share.

As “Administrative shares” are defined all the default network shares that can be accessed remotely only from network administrators. And there are some firewall settings which may block the connection.

More details please take a look at this blog.

PatrickLu-MSFT
  • 49,478
  • 5
  • 35
  • 62
  • 1
    Thanks - I have no access to the build service account... (Anyway, I've worked around that by switching to WebDeploy, but the question is still valid in case of FileSystem) And Connector is not Read Only, that's one of the things I tried when sharing it. – Bartosz Apr 21 '17 at 08:21
  • @Bartosz Since it works well with WebDeploy as workaround, probably not the IIS server issue. Most likely a security problem, you may need to ask someone which have access with the build service account to figure out it. – PatrickLu-MSFT Apr 21 '17 at 08:31
  • 1
    @Bartosz w$ is a **Admin share**. As “Administrative shares” are defined all the default network shares that can be accessed remotely only from network administrators. And there are some firewall settings which may block the connection. More details please take a look at this [blog](http://www.wintips.org/how-to-enable-admin-shares-windows-7/) Guess this is the root cause of access denied error. – PatrickLu-MSFT Apr 25 '17 at 10:20