asp.net memory architecture question ...

  • Thread starter Thread starter Ashish
  • Start date Start date
A

Ashish

hi all,
I have been doing some performance testing of a asp_net website, to be
hosted on a shared server ..

as far as i understand every page when accessed first time is compiled
and loaded in the memory of aspnet_wp , so that would mean more distinct
pages more the memory consumed by aspnet_wp, this is good since it would
mean serving compiled copy of the page , which is good for speed..

another understanding is that once a page is compiled and loaded nothing
except unloading app domain can make aspnet_wp to give up the memory for
the page , because when i start my performance tests memory builds up
quickly as i new pages are browsed first time, but then it stablizes
once new page hits end, and then i can increase as much load as i want,
the memory then sweetly fluctuates within a particular range..


My question is that can we make the worker process to unload some pages,
pages which are not being hit at all ?

because to me it seems like all this memory is there, which is not being
used, which I can reclaimed,

seond question is can i make a dormant appdomain unload ? like if there
are 100 webistes on a shared machine, can i make websites which are
dormant for last one hour unload themselves ? and would it make worker
process release that much memory

Any help or pointers would be appreciated...


thanks
-ashish
 
..net does not support unloading code, only an appdomain, so you cannot prune
the loaded pages, only unload the appdomain and start over.

machine.config or web.config already contain entries for automatically
unloading an appdomian.

also the OS's paging handles a lot of this for you. once the code for a page
is paged out, it taks no real memory only disk space (the code takes non -
only global data on the page need to be swapped out) , until the page is hit
again.


-- bruce (sqlwork.com)
 
bruce said:
.net does not support unloading code, only an appdomain, so you cannot prune
the loaded pages, only unload the appdomain and start over.

machine.config or web.config already contain entries for automatically
unloading an appdomian.

also the OS's paging handles a lot of this for you. once the code for a page
is paged out, it taks no real memory only disk space (the code takes non -
only global data on the page need to be swapped out) , until the page is hit
again.


-- bruce (sqlwork.com)

hi Bruce,

thanks for the info

then if i understand it correctly it will still account for the virtual
address space of the process, and though it might not be in the ram (
depending on how much the ram is ), it can still cause the worker
process to reach its limit and recycle

and also would be great if you could point me towards entries in .config
files which can make appdomains unload due to inactivity, it would be great

thanks again

-ashish
 
Windows Server 2003/IIS6 has settings to restart AppDomains based on time or
specificied number of requests.

Corey O'Mara
MCSD.NET, MCT
 
Back
Top