configuration - 无法读取配置文件,因为它超过了最大文件大小

标签 configuration iis-7.5 windows-server-2008-r2 url-rewrite-module

无法读取配置文件,因为它超过了最大文件大小。

我收到上述错误,因为我的 rewritemap.config 文件大小超过 250KB(Windows 2008 R2 SP1 服务器,带有 IIS 7.5

最佳答案

如果您有权访问注册表,并且确实需要大于 250kb 的文件,则可以更改注册表项中的值。

对于 x32 系统:

创建 key :

HKLM\Software\Microsoft\InetStp\Configuration\

添加 DWORD 值:
MaxWebConfigFileSizeInKB

对于 x64 系统:

创建 key :
HKLM\Software\Wow6432Node\Microsoft\InetStp\Configuration\

添加 DWORD 值:
MaxWebConfigFileSizeInKB

请务必重新启动或重新启动应用程序池。 This answer to a related question也可以启发。

注意:如果没有 key ,您可以创建它。 how to create a key on regedit

另一种选择是拆分 .config 文件。
http://forums.asp.net/t/1961321.aspx?Split+web+config+rewrite+rules+in+separate+file

关于configuration - 无法读取配置文件,因为它超过了最大文件大小,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22169084/

相关文章:

c# - ASP.NET 5 启动应用程序时出错

elasticsearch - 无法启动 Elasticsearch 服务

c# - 安全地将补丁应用到 COM+ 应用程序

configuration - 再次关于 log4net 和 Unity IOC 配置

node.js - 我可以在模块外使用 NestJS Config Service 吗?

android - Android 中的配置更改以及在实例状态中保存哪些变量

php - AJAX : Detect connection closed, PHP 继续

iis-7.5 - 注册后允许用户浏览到 username.host.com

reporting-services - 无法制作商业智能项目。如何解决 "Configuration system failed to initialize"错误消息?

visual-studio - 如何为不同的构建配置部署不同版本的文件?