0

Recently I am getting an error message when try to do anything on my website. It only happens randomly(no specific page).

Error is given below:

Server Error in '/' Application.

Validation of viewstat MAC failed. If this application is hosted by a web farm or cluster, ensure that configuration specifies the same validationKey and validation algorithm. Autogenerate cannot be used in a cluster."

I need your help in solving the problem.

Community
  • 1
  • 1
Swaroop
  • 21
  • 1
  • 3
  • 7
  • in a **WebFarm**, you need to deploy your site in all Servers, and they need to be called exactly the same under IIS, just changing the server name. Did you do that? – balexandre Sep 09 '11 at 08:58
  • you need to provide the exact error message coming from the application. – Martin Ongtangco Sep 09 '11 at 09:01
  • 1
    As the message is quite self-explaining, I assume you tried to manually set the machine keys as explained in the [documentation](http://msdn.microsoft.com/en-us/library/ff649308.aspx) ? – Steve B Sep 09 '11 at 09:09

1 Answers1

1

As a quick-fix, just switch viewstate MAC validation off (web.config).

(in <system.web>)

<pages enableViewStateMac="false">
Stefan Steiger
  • 78,642
  • 66
  • 377
  • 442
  • HI, I have already implemented the above solution in web.config file. But still getting the error. with regards, Swaroop Kumar.P – Swaroop Sep 09 '11 at 14:00