Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
375 views
in Technique[技术] by (71.8m points)

c# - 错误 - 无法访问IIS元数据库(Error - Unable to access the IIS metabase)

After installing Visual Studio 2012 and opening my solution I get a series of errors in this form:

(安装Visual Studio 2012并打开我的解决方案后,我收到以下形式的一系列错误:)

The Web Application Project Foo is configured to use IIS.

(Web应用程序项目Foo配置为使用IIS。)
Unable to access the IIS metabase.

(无法访问IIS元数据库。)

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

(您没有足够的权限访问计算机上的IIS网站。)

I get this for each of our web applications.

(我为每个Web应用程序都得到了这个。)

Things I have tried:

(我尝试过的事情:)

  1. Running Visual Studio as Administrator

    (以管理员身份运行Visual Studio)

  2. Running aspnet_regiis.exe -ga MyUserName

    (运行aspnet_regiis.exe -ga MyUserName)

  3. Running aspnet_regiis.exe -i

    (运行aspnet_regiis.exe -i)

These seem to be common solutions for this problem but I have not had any success with them.

(这些似乎是这个问题的常见解决方案,但我没有取得任何成功。)

Is there anything else I can try to do?

(还有什么我可以尝试做的吗?)

  ask by jjathman translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

On Windows 8 Pro :

(在Windows 8 Pro上 :)

%systemroot%inetsrvconfig

On Windows 7 and 8.1 and 10

(在Windows 7和8.1和10上)

%systemroot%System32inetsrvconfig 

(Where %systemroot% is usually C:\Windows )

(( %systemroot%通常是C:\Windows ))

Navigate to the appropriate location above in Windows Explorer.

(在Windows资源管理器中导航到上面的相应位置。)

You will be blocked access with a popup which says:

(您将被弹出窗口阻止访问:)

"You don't have access to this folder - Click continue to permanently get access to this folder"

(“您无权访问此文件夹 - 单击”继续“以永久访问此文件夹”)

Click 'continue' for this folder, and with the Export folder underneath.

(单击此文件夹的“继续”,然后单击下面的“导出”文件夹。)

I changed the shortcut back to "Run as me" (a member of the domain and local administrators ) and was able to open and deploy the solution.

(我将快捷方式更改回“以我身份运行”(域和本地管理员的成员)并能够打开和部署解决方案。)


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...