Troubleshooting Memory leaks
Document ID: 10418
Synopsis
This doecument should only be used in conjunction with a Support Engineer.
More Information
This doecument should only be used in conjunction with a Support Engineer.
Where the word 'ServiceName' is used please replace with the Service needs to be monitored. To perform the memory tracing we need to do the following -
-
Download and install the latest Windows Debugging tools from this location - http://www.microsoft.com/whdc/devtools/debugging/installx86.mspx
-
Setup Performance Monitor Counters
- Open performance Monitor and expand 'Performance Logs and Alerts'
- Select 'Counter logs'
- Right click and select 'New Log Settings'.
- Name is ServiceName Trace
- Click Add Counter and select the below options
- Performance Object = Process
- Select Counters from list = Private Bytes
- Instance = ServiceName
- Change the Interval to 5 Seconds from 15 seconds.
- Click ok and the counter will be logging the information
Leave this running for the period of the gathering of the information.
-
Installing vadump
- Download this file vadump.zip from this FTP location ftp.rockliffe.com/mailsite/tools/vadump.zip
- Unzip the file into the MailSite install directory.
-
Setting up MailSite logging
- Enable within the 'Server log Flags' - 'Service start and stop'
- Enable within the 'Operational log Flags' - 'Protocol exchanges'
-
Setting up MailSite Tracing
- Open the registry to this location - HKLM\Software\Rockliffe\MailSite
- Add a new String with the name of - EventCaptureRules
- Then add this entry without the single quotes- '::::16'
-
Running the test.
At **no point** during the test should the Service be stopped as this will invalidate all the data being gathered and end in us asking for the test to be run again.
- Stop the Service
- Start the Service
- Start our Tracing with this control code from the command prompt
within the MailSite install directory
ServiceName -control 133 -silent
- Start our memory tracing with this control code from the command
prompt within the MailSite install directory
ServiceName -control 136 -silent
- Leave the service running for 2 minutes then run this command from
the MailSite install directory
ServiceName -control 135 -silent
-
Also run this command from where you install the Windows Debugging tools
- cscript adplus.vbs -hang -pn ServiceName.exe -quiet -o
c:\adplus
And at the same time run this command from the MailSite install directory and make sure you take a copy of this file.
- ServiceName -control 130 -silent
- cscript adplus.vbs -hang -pn ServiceName.exe -quiet -o
c:\adplus
-
Then from Task Manager find the PID number for the Service then run this command for vadump
vadump -sot -PID > vadumpstart.txt
- Then let it run ***until the usage has grown by at least 30%***,
such that the leak is unambiguous. For the issues to be see you need to
have at least 200+ MB's shown in Task Manager Memory Usage Column before
running the below commands.
- ServiceName -control 135 -silent
- cscript adplus.vbs -hang -pn ServiceName.exe -quiet -o c:\adplus
- ServiceName -control 137 -silent
- ServiceName -control 134 -silent
- ServiceName -control 130 -silent
- Stop the Performance counter trace.
- vadump -sot -p PID > vadumpFinish.txt
We have now concluded the information gathering. This is what we need uploaded to the Cases FTP location.
- Zip the two ADPLUS hang dumps. These need to be in their own zip file
called ADPLUS.zip
Then the below files in a separate zip file called TraceInformation.zip
- Find the ServiceName.Memory-Trace.TXT
- Find the ServiceNameDUMP.TXT or ServiceNameDUMP.XML
- Zip the Performance counter log
- The two VADump traces
- All the MailSite logs
Then upload to the FTP share that has been assigned to your case.