Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Configuring IIS to run 32-bit applications on 64-bit Windows  (Read 9145 times)

0 Members and 1 Guest are viewing this topic.

vinayakk

  • Guest
Configuring IIS to run 32-bit applications on 64-bit Windows
« on: January 25, 2014, 03:19:58 pm »
If you wish to run a 32-bit web application under a Windows x64 VPS then you must switch IIS to run in 32-bit mode.

IIS 6.0 is able to run 32-bit Web applications on 64-bit Windows using the Windows-32-on-Windows-64 (WOW64) compatibility layer.

To enable IIS 6.0 to run 32-bit applications on 64-bit Windows

    1. Open a command prompt and navigate to the %systemdrive%\Inetpub\AdminScripts directory.
   
    2 . Type the following command:

    cscript.exe adsutil.vbs set W3SVC/AppPools/Enable32BitAppOnWin64 "true"


With IIS 7.0 the Enable32bitAppOnWin64 key has been moved to the Application Pool level. So you can now set the bitness of a particular Application Pool.

appcmd set apppool /apppool.name:DefaultAppPool /enable32bitapponwin64:true

This will make only the DefaultAppPool to run in 32 bit mode. You can have other application pools running simultaneously in 64 bit mode.

You can also list the apppools based on bitness using the appcmd command. To list all the application pools runningin 64bit mode use the following command

appcmd list apppools /enable32bitapponwin64:false

You can also set the application bool bitness via the IIS manager


    1. Right click on the Application Pool and select “Advanced Settings…” or select the same from the Actions pane after selecting the Application pool
    2. Change the “Enable 32-bit Applications” to True (if you want the application pool to spawn in a 32-bit mode)
    3 .Click OK



Now restart IIS (either via the snap-in or the command line w/net stop w3svc & net start w3svc) and you’re good to go. Pop open Task Manager  and you should see a  *32 next to the World Wide Web Worker Process (w3wp.exe), signifying that it’s basically running in 32-bit compatibility mode:



 :) :)