2

I have Visual Studio 2013 and a pretty basic MVC web application.

When I am connected to my work network (hard wire or VPN) I can open up VS without issue. However when not connected to my work network I get the following error:

---------------------------
Microsoft Visual Studio
---------------------------
Creation of the virtual directory http://localhost:54156/ failed with the error: Unable to access the IIS metabase. You do not have sufficient privilege to access IIS web sites on your machine.
---------------------------
OK   
---------------------------

I've tried granting my user rights to IIS via the aspnet_regiis -ga mydomain\myuser and that did not help.

I am certainly running VS as an administrator. It works just fine when connected to the network. Our security and server teams do not seem to understand why this would behave this way.

Clarence Klopfstein
  • 4,682
  • 10
  • 33
  • 47

3 Answers3

0

Is this IIS Express? I (and those I work with) often get a similar error due to the domain login script encrypting My Documents. It's fixed by simply decrypting

Documents\IISExpress\config\applicationhost.config

Not sure if that's the issue here though;

Chad Schouggins
  • 3,440
  • 2
  • 23
  • 29
0

Ultimately I believe this to be an issue between our network policies and the IIS and .NET installs.

When I was off network it could not access the cached user folders. Switching from having the home drives on network to having them local did not fix the issue (assuming some files were still referencing the network location).

I had my system refreshed and started with my user folders as local and have not had the issue since.

Clarence Klopfstein
  • 4,682
  • 10
  • 33
  • 47
0

I know it's an old question, but at my location the user profile is stored on the network. When I checked to see if the IISExpress application was encrypted as Chad Schouggins suggested, I didn't even have a documents folder. Ultimately, the answer was really simple:

turn the machine off and back on again.
Justin
  • 541
  • 7
  • 15