在 IIS 7 上发布 Web 服务出现 500.19 - 内部服务器错误

发布于 2024-09-05 08:59:10 字数 184 浏览 3 评论 0原文

我创建了一个文件夹并将我的网络服务发布到该文件夹​​。然后我创建了一个应用程序(在 IIS 7 中)并将其指向此文件夹位置。当我尝试从本地计算机上的浏览器点击 ASMX 文件时,出现以下错误:

HTTP 错误 500.19 - 内部服务器错误 无法访问所请求的页面,因为该页面的相关配置数据无效。

有人能告诉我为什么吗?

I have created a folder and published my webservice to this folder. I then created an application (in IIS 7) and pointed it at this folder location. When I try and hit the ASMX file from a browser on the local machine I get the following error:

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.

Can someone tell me why?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

旧时模样 2024-09-12 08:59:10

反过来试试这个。直接发布到 IIS,并选择创建虚拟目录。让 Visual Studio 按照其想要的方式配置虚拟目录(或应用程序)。

Try this the other way around. Publish directly to IIS, taking the option to create the virtual directory. Let Visual Studio configure the virtual directory (or application) the way it wants to.

爱殇璃 2024-09-12 08:59:10

好像和web.config文件有关,先检查一下。

另外,也许你错过了在IIS中注册asp.Net,你可以在服务器上运行aspnet_regiis.exe,带有-i标志

C:\WINDOWS\Microsoft.NET\Framework\<your framework version here>>aspnet_regiis.exe -i
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319>aspnet_regiis.exe -i

阅读你的错误报告,我发现你还没有安装System.Web.Extensions dll,安装它并/或将其放在您的 bin 文件夹中 (System.Web.Extensions.dll)

It seems to be something related with the web.config file, check it first.

Also, ,maybe you missed registering asp.Net in IIS, you can run aspnet_regiis.exe on the server, with the -i flag

C:\WINDOWS\Microsoft.NET\Framework\<your framework version here>>aspnet_regiis.exe -i
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319>aspnet_regiis.exe -i

Reading your error report, I see you have not installed the System.Web.Extensions dll, Install it and/or put it on your bin folder (System.Web.Extensions.dll)

德意的啸 2024-09-12 08:59:10

授予 IIS_IUSRS 组对该文件夹的权限。另外,在IIS管理器->“应用程序池”中查看该应用程序的应用程序池的标识是什么。将其设置为“LocalSystem”。

Give permissions to the folder for the IIS_IUSRS group. Also, see what is the Identity of the application pool for the application in IIS manager->"Application Pools".Set it as "LocalSystem".

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文