最近,我们将所有网站从一台服务器(IIS6)移至新服务器(IIS7),该服务器还涉及更改所有DNS记录。但是,在某些网站上,当您在某些页面上进行后背包时,您会收到以下错误:

Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.Web.HttpException: Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

起初,我认为这可能是该站点的一个促进问题(即,它试图在旧服务器上进行后退)。但是,DNS的记录在两周前发生了变化,因此肯定情况下并非如此。

为什么会发生此错误?

可能值得注意,此错误从未发生在旧服务器上。

有帮助吗?

解决方案

这可能是与ASP.NET-2.0有关的错误。您正在使用哪个版本 - 该错误已固定在SP2中。

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top