I'm running this PerfView command:
PerfView.exe /Merge:true /zip:true /NoNGenRundown /NoClrRundown /KeepAllEvents /ThreadTime /DumpHeap /NoView /NoGui /MaxCollectSec:30 collect
but it seems that even if I defined /MaxCollectSec:30
to 30 seconds the actual data collection process is not stopping and keep adding data to PerfViewData.etl
file
This is the output from console windows that Perfview open when running command:
VERBOSE LOG IN: PerfViewData.log.txt
EXECUTING: PerfView /Merge:true /zip:true /NoNGenRundown /NoClrRundown /KeepAllEvents /ThreadTime /DumpHeap /NoView /NoGui /MaxCollectSec:30 collect
Pre V4.0 .NET Rundown disabled, Type 'E' to enable symbols for V3.5 processes.
Do NOT close this console window. It will leave collection on!
Type S to stop collection, 'A' will abort.
Kernel Log: C:\PerfView\PerfViewData.kernel.etl
User mode Log: C:\PerfView\PerfViewData.etl
Starting collection at 12/07/2017 14:26:32
Collecting 10 sec: Size= 10.5 MB.
Collecting 20 sec: Size= 16.4 MB.
Exceeded MaxCollectSec 30
So here it is: Exceeded MaxCollectSec 30
but keep writing to etl files.
I want to send to client an Perfview command to collect system wide data and send me back the zip file with all ETL files from Perfview. Currently command does not stop - somebody know why ? What should I add/remove from command so it will stop automatically after 30 seconds ?
I know it's been a while, but it looks like the /DumpHeap
switch is the problem here - if you remove it, the trace will finish on time. I checked the PerfView source code and when DumpHeap is selected there is some interaction with the GUI window:
if (parsedArgs.DumpHeap)
{
// Take a heap snapshot.
GuiHeapSnapshot(parsedArgs, true);
// Ensure that we clean up the heap snapshot state.
parsedArgs.DumpHeap = false;
}
You may create an issue in perfview describing your problem.