Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio 2013. You do not have sufficient privilege to access IIS web sites on your machine

I just installed VS2013 and turned on IIS 7 on my Windows 7 Ultimate x64 machine. When trying to open a solution I get:

Creation of the virtual directory localhost:xxxxx failed with the error: Unable to access the IIS metabase. You do not have sufficient privilege to access IIS web sites on your machine.

I tried running Visual Studio 2013 as Administrator (right click, run as administrator), still the same error. I also did aspnet_regiis -i and it didn't help either.

like image 784
user3171214 Avatar asked Jan 08 '14 00:01

user3171214


2 Answers

Go to C:\Windows\System32\inetsrv. Click config folder. You will get a popup - "You don't have access to this folder - Click continue to permanently get access to this folder". Perform same for Export folder which is inside config folder. You should be able to open the solution and the web application project will be deployed on IIS.

enter image description here

like image 79
Raj Chaurasia Avatar answered Sep 24 '22 11:09

Raj Chaurasia


The root cause of this error for me was that IIS was installing the config folder on a network shared drive at my workplace. I had to change this to use a local drive and it fixed it.

IIS creates an IISExpress folder in your %USER_HOME%/Documents folder (which for me was a shared drive)

For me this issue was solved by uninstalling IIS, and clearing everything IIS related in the registry. I then had to change my Documents drive in Registry (KHCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders) from a shared drive to a local drive (C:\Users[profile]\Documents).

Then reinstall IIS. It should create an IISExpress in the new Documents folder.

like image 39
dannash918 Avatar answered Sep 22 '22 11:09

dannash918