memory leaks - Azure service dies after a few days -


i have small size (x2) cloud service running , operating fine 4-6 days becomes unresponsive , requires manual restart through azure portal online.

windows event logs show virtual memory running low. after 2-3 days start getting:

windows diagnosed low virtual memory condition. following programs consumed virtual memory: waiishost.exe (3836) consumed 3810709504 bytes, cacheservice.exe (1528) consumed 823902208 bytes, , w3wp.exe (1728) consumed 145485824 bytes.

after while services start failing (due memory problem??):

application: cacheservice.exe framework version: v4.0.30319
description: process terminated due unhandled exception. exception info: microsoft.applicationserver.caching.configstoreexception
stack: @ microsoft.applicationserver.caching.customproviderproxy+<>c_displayclass5.b_3(system.object)
@ system.threading.executioncontext.run(system.threading.executioncontext, system.threading.contextcallback, system.object, boolean) @ system.threading.queueuserworkitemcallback.system.threading.ithreadpoolworkitem.executeworkitem()
@ system.threading.threadpoolworkqueue.dispatch() @ system.threading.threadpoolwaitcallback.performwaitcallback()
|http://schemas.microsoft.com/win/2004/08/events/event'>1026200x800000000000001138applicationrd00155d45a2adapplication: cacheservice.exe framework version: v4.0.30319 description: process terminated due unhandled exception.
exception info: microsoft.applicationserver.caching.configstoreexception
stack: @ microsoft.applicationserver.caching.customproviderproxy+<>c
_displayclass5.<performoperation>b__3(system.object)
@ system.threading.executioncontext.run(system.threading.executioncontext, system.threading.contextcallback, system.object, boolean) @ system.threading.queueuserworkitemcallback.system.threading.ithreadpoolworkitem.executeworkitem()
@ system.threading.threadpoolworkqueue.dispatch() @ system.threading._threadpoolwaitcallback.performwaitcallback()

and http requests start failing:

process information:
process id: 3344
process name: w3wp.exe
account name: nt authority\network service
exception information:
exception type: httpexception
exception message: paging file small operation complete. (exception hresult: 0x800705af) @ system.web.compilation.buildmanager.reporttoplevelcompilationexception()
@ system.web.compilation.buildmanager.ensuretoplevelfilescompiled()
@ system.web.hosting.hostingenvironment.initialize(applicationmanager appmanager, iapplicationhost apphost, iconfigmappathfactory configmappathfactory, hostingenvironmentparameters hostingparameters, policylevel policylevel, exception appdomaincreationexception)
paging file small operation complete. (exception hresult: 0x800705af)

i'm not sure if problem virtual memory configured low, or use of memory high. waiishost.exe virtual memory use looks quite high, seems stabilize @ around 4.1 gb.

i not know why waiishost.exe need much, since run() method doing light housekeeping activities, such pinging site every few minutes keep application running during daytime.

available memory monitoring in azure portal shows service have 300-800mb of free memory during whole period before crash.

any ideas problem? how can configure virtual memory higher?

you have memory leak in app code, catching in azure exceptions after effect of environment running out of memory because of app code consuming of it, experience.

normally when rdp box identify process has memory leak , start profiling session of code redgate tool (or other tool). run process half day tool , should identify problem is.

you find guess exception causing code not clean correctly. explain why see problem after couple of days , couple of exceptions. @ exception handling , clean code. should test disconnects in code base , other transient positions might effect code.

i stick in newrelic or foglight clear heads code/azure instance fail can see timescales on failures , possible more logging info , if there causing issues experiencing.


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -