dotnet-trace collect --process-id 67295 -o C:\users\myuser\trace
results in a file trace
dotnet-trace collect --process-id 67295 -o C:\users\myuser\trace.nettrace
results in a file trace.trace.netrace
in C:\users\myuser\
Edit (@hoyosjs):
The issue that persists is now https://github.com/dotnet/diagnostics/issues/1352#issuecomment-659180703
dotnet-trace collect -p24084 -o trace.nettrace -f speedscope
Results in
Writing: C:\Usersjfriedman\trace.speedscope.json
file name is trace.speedscope.json so looks like that is still partially a problem
The problem still kinda exists for speedscope format files as indicates in my other thread @hoyosjs .
Thank you again for your help!
Your speedscope issue sounds like #1218 which was fixed by #1313 and should be in the next release.
For the filename issue, I'm not sure what would be causing that. The current code doesn't make any changes to provided argument:
https://github.com/dotnet/diagnostics/blob/81c1ed54776ac8add8cfe9f311b9d8dda78a9c8e/src/Tools/dotnet-trace/CommandLine/Commands/CollectCommand.cs#L341-L347
All other uses are simply output.FullName.
At least, that's how it is in the current version; what version of dotnet-trace are you using?
He was using "5.0.0-preview.20360.1" (just 2 or 3 days old) when he saw this.
That is correct @hoyosjs
I was unable to reproduce this issue with the newest version of dotnet-trace:
$ dotnet trace collect -p 10791 -o trace
No profile or providers specified, defaulting to trace profile 'cpu-sampling'
Provider Name Keywords Level Enabled By
Microsoft-DotNETCore-SampleProfiler 0x0000F00000000000 Informational(4) --profile
Microsoft-Windows-DotNETRuntime 0x00000014C14FCCBD Informational(4) --profile
Process : /usr/local/share/dotnet/dotnet
Output File : /Users/josalem/trace
[00:00:01:37] Recording trace 4.4445 (MB)
Press <Enter> or <Ctrl+C> to exit...
Stopping the trace. This may take up to minutes depending on the application being traced.
Trace completed.
$ dotnet trace collect -p 10791 -o trace.nettrace
No profile or providers specified, defaulting to trace profile 'cpu-sampling'
Provider Name Keywords Level Enabled By
Microsoft-DotNETCore-SampleProfiler 0x0000F00000000000 Informational(4) --profile
Microsoft-Windows-DotNETRuntime 0x00000014C14FCCBD Informational(4) --profile
Process : /usr/local/share/dotnet/dotnet
Output File : /Users/josalem/trace.nettrace
[00:00:00:02] Recording trace 223.755 (KB)
Press <Enter> or <Ctrl+C> to exit...
Stopping the trace. This may take up to minutes depending on the application being traced.
Trace completed.
-o trace --> a file named trace
-o trace.nettrace --> a file named trace.nettrace
Is this still an issue?
I'll close this for now as "no repro." If we can get more details or a repro showing this is still an issue, we can open it back up 馃榿