Web Deployment Project IIS Deploy error RRS feed

  • Question

  • User511144497 posted

    I get the following  when I build locally

     if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"
    C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_compiler.exe -v /WebSite -p C:\Projects\YourClubMatters\Trunk\YCM\WebSite -f -c .\TempBuildDir\
    Running aspnet_merge.exe.
    C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin\aspnet_merge.exe .\TempBuildDir -o WebSite_deploy -a  -r -copyattrs
    Successfully merged '.\TempBuildDir'.
    if exist "C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release\" rd /s /q "C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release\"
    if not exist "C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release\" md "C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release\"
    if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"
    Initializing IIS Web Server...
    Successfully created virtual directory 'ycmbuild'.
    Granting IIS read access to the folder 'C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release'.
    C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(676,5): error : Some or all identity references could not be translated.
    Warning: Unable to grant IIS access to folder 'C:\Projects\YourClubMatters\Trunk\YCM\WebSite_deploy\Release'.

    Done building project "WebSite_deploy.wdproj".
    ========== Rebuild All: 7 succeeded, 0 failed, 0 skipped ==========

     I get this error when building locally or on the team foundation server.

     Not exactly sure how to solve it, have the iis app pool and web site running as the tfs user so it doesn't have any problem viewing the website but the error is really irritating as its always telling me my build is broken.

    Friday, March 13, 2009 11:20 AM


All replies

  • User511144497 posted

     still haven't solved this issue

    Saturday, March 14, 2009 6:04 PM
  • User372121194 posted


    The error is often a permission issue caused when the process identity cannot access the directory. The process identity is ASPNET for IIS 5.1 and is Network Service for IIS 6.0, 7.0.

    To resolve this issue, we can grant IIS process identity access permission on that file. For more information, see http://technet.microsoft.com/en-us/library/cc753525.aspx.

    We also need to make sure ASP.NET has the required permissions. For required permissions, see http://msdn.microsoft.com/en-us/library/kwzs111e.aspx


    I look forward to receiving your test results.

    Tuesday, March 17, 2009 10:52 PM
  • User511144497 posted

     IIS is saying that it can't access the folder

    The server is configured to use pass-through authentication with a built-in account to access the specified physical path. However, IIS Manager cannot verify whether the built-in account has access. Make sure that the application pool identity has Read access to the physical path. If this server is joined to a domain, and the application pool identity is NetworkService or LocalSystem, verify that <domain>\<computer_name>$ has Read access to the physical path. Then test these settings again.

    However I can run the application by going to browser and enter in http://localhost/application

    This happens when application pool identity is set to NetworkService

    When I set it to administrator it works fine

    Wednesday, March 18, 2009 9:15 AM
  • User511144497 posted

     just to clarify when I set it to administrator it works fine but web deployment project still gives the same error

    Wednesday, March 18, 2009 9:16 AM
  • User372121194 posted


    Thanks for your response.

    Since the error is thrown when we try to build it with Visual Studio, please make sure you log in system using Administrator role and run Visual Studio as Administrator(right-click Visual Studio, and then click Run as administrator).


    I look forward to receiving your test results.

    Wednesday, March 18, 2009 11:49 PM
  • User511144497 posted

    When I run Visual Studio as the administrator it still produces the same result.

    I normally run it using an admin account but I actually right clicked on the app and ran as admin like you said.

    Thursday, March 19, 2009 7:12 AM
  • User511144497 posted

     Found the solution and posted here


    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, March 30, 2009 9:57 AM