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.
把文件web.config里面的
<pages validateRequest="false" enableSessionState="true" enableViewState="true"/>
改成
<pages validateRequest="false" enableSessionState="true" enableViewStateMac="false" enableViewState="true"/>
一切ok
本文介绍了解决ASP.NET中ViewState MAC验证失败的问题。通过修改web.config文件中的配置,禁用ViewState MAC验证,解决了集群环境中应用无法正常运行的问题。

被折叠的 条评论
为什么被折叠?



