문제

We've recently moved all our sites from one server (IIS6) to a new server (IIS7) which has also involved changing all the DNS records. However, on some of the sites, when you make a post-back on certain pages, you get the following error:

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.

At first I thought this may be a propogation issue with the site (Ie. its trying to post-back to the old server). However, the DNS records were changed over 2 weeks ago, so surely this cannot be the case.

Why would this error be occuring?

It might be worth noting, this error never occurred on the old server.

도움이 되었습니까?

해결책

This may be a bug related to asp.net-2.0. Which version are you using - the bug is fixed in SP2.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top