Amjad
Amjad

Reputation: 19

Server Error due to configuration, and can't set up machine key as shown below

Server Error in '/' Application.

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: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:

Line 9:    </connectionStrings>
Line 10:   <system.web>
Line 11:     <machineKey decryption="AES"           decryptionKey="D5BE1C3052D930D3D425E96D7A424FEDF67AC4CDDD1BB523A8F420A6C9AB8779"     validation="HMACSHA256" validationKey="8AE05954FF94F7FE9972E9774B94B1E7F6
Line 12: 4717979FE0B230158BC7A8AE588994E7EC66CFAC555BA276AEC669BBE8B15DC52A04B06395018BFF3BBAE221E0149A" />
Line 13:     <customErrors mode="Off"/>

Source File: C:\Inetpub\vhosts\connectnewwings.com\httpdocs\admin\web.config    Line: 11 

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34237

Upvotes: 0

Views: 3322

Answers (1)

Roman Marusyk
Roman Marusyk

Reputation: 24569

Configuration information for an ASP.NET website is defined in one or more Web.config files. The configuration settings are applied in a hierarchical manner. There's a “global” Web.config file that spells out the baseline configuration information for all websites on the web server; this file lives in the %WINDIR%\Microsoft.Net\Framework\version\CONFIG folder. You can also have a Web.config file in the root folder of your website. This Web.config file can override settings defined in the “global” Web.config file, or add new ones. Additionally, you may have Web.config files in the subfolders of your website, which define new configuration settings or override configuration settings defined in Web.config files higher up in the hierarchy.

Certain configuration elements in Web.config cannot be defined beyond the application level, meaning that they must be defined in the “global” Web.config file or in the Web.config file in the website's root folder. The element is one such example. The above error message indicates that there is a Web.config file in one of the website's subfolders than has one of these configuration elements that cannot be defined beyond the application level.

Source: http://scottonwriting.net/sowblog/archive/2010/02/17/163375.aspx

Upvotes: 1

Related Questions