Monday, September 28, 2009

Invalid win32

Got weird errors like: invalid win32 application.

This is due to the following scenario:

64Bit IIS7 running a 32Bit application so Enable 32Bit is set to true on the application pool
Also running as an exchange front end server and hence RPCProxy is loaded

In this scenario you might get the errors

In IE -
"HTTP Error 503. The service is unavailable."


In the event viewer-
"The Module DLL C:\Windows\system32\RpcProxy\RpcProxy.dll failed to load. The data is the error."
and
"Application pool 'xxxxxxxxx' is being automatically disabled due to a series of failures in the process(es) serving that application pool."

Essentially the rpcpoxy is trying to load into the 32bit pool. The question I have i guess is why is this dll trying to load in the first place. It's not part of my application. Anyway to fix this issue:

Edit c:\windows\system32\inetsrv\config\applicationhost.config

In the section which has add - precondition="bitness64" to the rpcproxy line so that you have the following

No comments: