IIS deployment site Related experience summary

Source: Internet
Author: User

IIS deployment site Related experience summary

1.IIS and . net4.0 installations are sequential, you should install the . NET Framework 4.0 first, and then install IIS. If you install in reverse order,IIS does not see Anything related to 4.0, then you can only perform command enablement:

C:\windows\system32> C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_regii.exe-ir-enable

      2. Iis " "LocalSystem", "Local service", "Network service", using the default " applicatonpoolidentity " So if you are connected to a local database, you may not be able to connect because of security restrictions, and you can change the application identity to "LocalSystem" in the application pool advanced settings process model. Maybe it will be all right.

3.machineKey: It is machine.config by default at the ASP . NET Framework level (C:\Windows\Microsoft.NET\ Framework64\v4.0.30319\config) , It is dynamically generated by the . NET Framework by default , The build on different servers is not the same, but the cluster scenario must be the same, or there will be errors during some encryption and decryption process:

4. Be aware of the differences between the IIS application Pool Classic mode and the integrated mode, which are analyzed according to the specific scenario.

Case 1: when deploying in a load-balanced manner, the ViewState validation fails due to different machinekey on multiple servers .

Server Error in "/" application.

Validation of ViewState MAC failed. If This application are hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same VA Lidationkey and validation algorithm. AutoGenerate cannot is used in a cluster.

See http://go.microsoft.com/fwlink/?LinkID=314055 for more information.

Description : An unhandled exception occurred during the execution of the current WEB request. Check the stack trace information For more information about the error and the source of the error in your code.

exception Details : System.Web.HttpException:Validation of ViewState MAC failed. If This application are hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same VA Lidationkey and validation algorithm. AutoGenerate cannot is used in a cluster.

See http://go.microsoft.com/fwlink/?LinkID=314055 for more information.

Source Error :

[ no related source line ]


Source file : c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP. Files\root\a59f6e56\410d1464\app_ Web_uydhjhqj.5.cs Line : 0

Stack trace :

Case 2: The application pool identity is improperly set, resulting in an inability to connect to the . \SQLExpress instance on the machine

Unable to open the database "WYGL"requested by the login. Login failed.
The user ' IIS apppool\ielong ' logon failed.

:&NBSP; Execute current  < Span style= "font-family:arial;" >web  During the request, an unhandled exception occurred. Check the stack trace information For more information about the error and the source of the error in your code. &NBSP;

:&NBSP; system.data.sqlclient.sqlexception: 
user   "IIS  apppool\ielong '   Login failed.

:  

An unhandled exception was generated during the execution of the current WEB request. You can use the following exception stack trace information to determine information about the cause of the exception and where it occurred

Case 3: v4.0 related ISAP and CGI extensions are not enabled, causing the site to be unusable

Friend's product "easy lung Property Management system" problem, contact me to help solve. I encountered the following exception message when I visited:

============================2015-07-31 00:12:57==============================

Ip:

Message: to process this request, the WebResource.axd handler must be registered in the configuration .

<!--the Web. config configuration file --

<configuration>

<system.web>

<add path= "WebResource.axd" verb= "GET" type= "System.Web.Handlers.AssemblyResourceLoader" validate= "True"/>

</system.web>

</configuration>

Stack: in System.Web.Handlers.AssemblyResourceLoader.GetWebResourceUrlInternal (Assembly Assembly, String resourcename, Boolean htmlencoded, Boolean forsubstitution, Iscriptmanager ScriptManager)

In System.Web.Handlers.AssemblyResourceLoader.GetWebResourceUrl (type type, String resourcename, Boolean htmlencoded, Iscriptmanager ScriptManager)

In System.Web.UI.ClientScriptManager.GetWebResourceUrl (Page owner, type type, String resourcename, Boolean htmlencoded, Iscriptmanager ScriptManager)

In System.Web.UI.ClientScriptManager.RenderWebFormsScript (HtmlTextWriter writer)

In System.Web.UI.Page.RenderWebFormsScript (HtmlTextWriter writer)

In System.Web.UI.Page.BeginFormRender (HtmlTextWriter writer, String Formuniqueid)

In System.Web.UI.HtmlControls.HtmlForm.RenderChildren (HtmlTextWriter writer)

In System.Web.UI.HtmlControls.HtmlContainerControl.Render (HtmlTextWriter writer)

In System.Web.UI.HtmlControls.HtmlForm.Render (HtmlTextWriter output)

In System.Web.UI.Control.RenderControlInternal (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.Control.RenderControl (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.HtmlControls.HtmlForm.RenderControl (HtmlTextWriter writer)

In System.Web.UI.Control.RenderChildrenInternal (HtmlTextWriter writer, ICollection children)

In System.Web.UI.Control.RenderChildren (HtmlTextWriter writer)

In System.Web.UI.Control.Render (HtmlTextWriter writer)

In System.Web.UI.Control.RenderControlInternal (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.Control.RenderControl (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.Control.RenderControl (HtmlTextWriter writer)

In System.Web.UI.Control.RenderChildrenInternal (HtmlTextWriter writer, ICollection children)

In System.Web.UI.Control.RenderChildren (HtmlTextWriter writer)

In System.Web.UI.Page.Render (HtmlTextWriter writer)

In System.Web.UI.Control.RenderControlInternal (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.Control.RenderControl (HtmlTextWriter writer, controladapter adapter)

In System.Web.UI.Control.RenderControl (HtmlTextWriter writer)

In System.Web.UI.Page.ProcessRequestMain (Boolean Includestagesbeforeasyncpoint, Boolean Includestagesafterasyncpoint)

====================================end======================================

Think down, is not the application pool type reason, a look at the application pool is now using the integration, replaced by classic try,

Change the application pool to classic and then encounter an error:
HTTP Error 404.2-not Found
The page you requested cannot be provided because of the ISAPI and CGI Restrictions list settings on the WEB server.
Then go to IIS7.5 's "ISAPI and CGI restrictions", and see that the ASP. NET v4.0 is in "Disallowed" state,


The 4.0 related to the activation is good ...

IIS deployment site Related experience summary

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.