3

I've got a legacy ASP web application that uses a VB6 DLL. The app is quite memory hungry. I need to run multiple instances of the app on one machine. Now since VB6 DLLs are 32bit only, running in a 64bit process is out - but what if I ran multiple 32bit IIS app pools? Would the memory limit of 1.2 GB per kick in per app pool, or would there by a memory limit for all app pool processes aggregated? Anyone who has experience with that?

2 Answers 2

7

but what if I ran multiple 32bit IIS app pools? Would the memory limit of 1.2 GB per kick in per app pool, or would there by a memory limit for all app pool processes aggregated?

The per process limit applies per process, and each app pool is in its own process. So you can make use of an arbitrary large amount of memory by running lots of app pools.

Also, it is not 1.2GB, but 4GB.

By default a 32bit process gets 2GB of "user space", unless the exe is built with the "Large Address Aware" flag, in which case it gets 3GB on a 32bit OS with the appropriate boot time flag (which limits kernel space—with its own consequences) but on a 64bit OS it is 4GB user space (no boot flag needed, and no kernel memory consequences).

The 32bit w3wp.exe (the executable that hosts app pools) is built with the Large Address Aware flag, as can be seen from running dumpbin /headers w3wp.exe in the %SystemRoot%\SysWow64\inetsrv folder.

5
  • 1
    In addition, MS recomends using 32 bit in IIS app pools anyway. Has performance benefits and rarely a web app needs 64 bit address space.
    – TomTom
    Sep 16, 2010 at 14:26
  • @TomTom: Certainly, and hosted on a 64bit OS means that each 32bit worker has lots of headroom anyway, so memory needs would be very high to push towards a 64bit worker.
    – Richard
    Sep 17, 2010 at 9:48
  • Exactly. This is different for databases etc. - but few web apps have the needs for more than 2-3 gb of memory in a process. Caching is better done at other layers (like IIS output cache).
    – TomTom
    Sep 17, 2010 at 12:57
  • 1
    @TomTom: Do you know where it's documented, that 32-bit application pools are recommended?
    – Mas
    Oct 11, 2011 at 9:14
  • 1
    learn.iis.net/page.aspx/201/32-bit-mode-worker-processes ;) I sugest you read the complete section with hosting guidance. Lots of nice hidden gems there.
    – TomTom
    Oct 11, 2011 at 9:46
1

Just to add a nuance in your original post, you CAN effectively use this 32-bit DLL from a native IIS 64-bit Application Pool.

Basically, you have to encapsulate this DLL using a COM+ Component Service. This will take you 5 minutes, and you can use your regular Classic ASP source code, without any change (Server.CreateObject).

I am using this procedure for some of my custom DLLS, and for other that are not available anymore in any other version than a 32-bit DLL.

The procedure is explained here : http://www.chestysoft.com/component-services.asp

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .