[Configuration] detects the solution to ASP. NET settings that are not applicable in integrated managed pipeline mode (not simply set to [classic] mode ).

Source: Internet
Author: User
Tags website performance

 

We port the ASP. NET program from IIS6 to IIS7, and the following error may occur:

  

  

  Why are the above errors?

The IIS7 application pool has two modes: "integration mode" and "Classic mode ".

Classic mode is the way we used to use IIS 6.

If you use the integration mode, you need to modify the configuration file for the custom httpModules and httpHandlers and transfer them to the <modules> and

  Two solutions:

 

Method 1: configure the application pool

Configure the application pool on IIS7 and change the mode of the application pool to "classic". Then everything works normally.

Enter the error message prompted above in the search engine, and almost all the searched results are directly changed to "classic.

However, this is only a matter of expediency. IIS7.x is used, but only six functions are used. In addition, some ASP. net mvc programs do not work well. Therefore, we try the following solutions:

 

Method 2: Modify the web. config configuration file:

 

For example, the original settings (You may not have the httpModules or httpHandlers node in your environment)

<system.web>    ............    

When the IIS7 application pool is "integration mode", change:

<system.web>    ...........</system.web><system.webServer>    <modules>      <add name="MyModule" type="MyApp.MyModule" />          </modules>    

(If your web. config does not have an httpModules or httpHandlers node, add the following directly to the node system. webServer:

<Validation validateIntegratedModeConfiguration = "false"/>
In this way, the integration mode cannot be verified to avoid error prompts.
Classic mode VS Integrated mode Classic ModeIIS uses the ISAPI extension (ISAPI extension aspnet_isapi.dll) and ISAPI filter (ISAPI filter aspnet_filter.dll) to call the ASP. NET Runtime Library to process requests. If the Classic mode is used, the server uses two pipelines to process the request. One is responsible for the source code and the other is responsible for hosting the code. In this mode, applications cannot fully use the services provided by IIS7.X. Integration ModeIs a unified request processing pipeline, which combines the ASP. NET Request pipeline with the IIS core pipeline. In integration mode, ASP. NET enters the IIS core from the role of the IIS plug-in (IIS extension) to monitor each request and operation. In integration mode, ASP. NET can run in IIS more effectively and effectively improve the website performance. Some codes developed in IIS6 need to run in the Classic mode, because an error message occurs in the integration mode. To use the services provided by IIS7 more effectively, we recommend that you put the website in integrated mode and solve the problem according to the error message.

 




For more principles, please share your comments!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.