IIS7 deployment - duplicate #39;system.web.extensions/scripting/scriptResourceHandler#39; section(IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler部分)
问题描述
尝试在 IIS7 的默认应用程序池上部署 .net 3.5 网站并将框架部分设置为 4.0 时,我收到以下错误.
On attempting to deploy a .net 3.5 website on the default app pool in IIS7 having the framework section set to 4.0, I get the following error.
有一个重复system.web.extensions/scripting/scriptResourceHandler"部分已定义.
There is a duplicate 'system.web.extensions/scripting/scriptResourceHandler' section defined.
评论有问题的行也无济于事.关于我需要做什么或看什么的任何指示?
Commenting off the offending lines didn't help either. Any pointers on what I need to do or look at?
推荐答案
如果您的计划是部署到具有在 .net 4.0 中运行的应用程序池的 IIS,您将需要清理包含所有部分的 web.config指向 .net 3.5 的定义.失败的原因是因为这些节定义已经包含在 .NET 4.0 的根 web.config 中(请参阅 %windir%microsoft.netframeworkv4.0.30319configmachine.config),其中包括所有系统.web.extensions 已经声明.
If your plan is to deploy to an IIS that has an Application Pool running in .net 4.0 you will need to cleanup the web.config that includes all the section Definitions that point to .net 3.5. The reason this fails is because these section definitions are already included in the root web.config in .NET 4.0 (see %windir%microsoft.netframeworkv4.0.30319configmachine.config) that include all the system.web.extensions declared already.
另一个快速解决方法是将应用程序池设置为 2.0,就像您的开发机器看起来一样.
Another quick fix is to have the application pool set to 2.0 just as your development machine appears to have,.
这篇关于IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分
基础教程推荐
- MS Visual Studio .NET 的替代品 2022-01-01
- 如何在 IDE 中获取 Xamarin Studio C# 输出? 2022-01-01
- 如何激活MC67中的红灯 2022-01-01
- 将 Office 安装到 Windows 容器 (servercore:ltsc2019) 失败,错误代码为 17002 2022-01-01
- 有没有办法忽略 2GB 文件上传的 maxRequestLength 限制? 2022-01-01
- 将 XML 转换为通用列表 2022-01-01
- SSE 浮点算术是否可重现? 2022-01-01
- rabbitmq 的 REST API 2022-01-01
- c# Math.Sqrt 实现 2022-01-01
- 为什么Flurl.Http DownloadFileAsync/Http客户端GetAsync需要 2022-09-30