IIS6到IIS7 - 根元素必须与引用该文件的部分名称匹配,'appSettings'

时间:2011-10-04 17:33:00

标签: iis-7.5

我正在将所有本地主机应用程序从WinXP / IIS6计算机移动到Win7 / IIS7.5计算机。我从WinXP的wwwroot目录复制了几个文件夹到Win7的wwwroot。然后创建一个虚拟目录并转换为一个应用程序。当我浏览这个应用程序时,我收到错误:

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: The root element must match the name of the section referencing the file, 'appSettings'

Source Error:

Line 1:  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
Line 2:  <html xmlns="http://www.w3.org/1999/xhtml">
Line 3:  <head>
Line 4:  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />


Source File: C:\inetpub\wwwroot\iisstart.htm    Line: 2

我错过了什么?

1 个答案:

答案 0 :(得分:1)

此应用程序的默认应用程序池是.Net 4.0。将其更改为另一个v2.0的apppool,错误就消失了。