当我从Windows命令行运行log.cmd
时,我从xperf
收到错误,指出*.etl
文件已存在。我知道其他进程也使用Windows ETL,并且gpuview
使用xperf
来跟踪事件,它在某种意义上“碰撞”。
尽管如此,我还是通过再次运行log.cmd
来获得大量合并的ETL文件。
我讨厌使用cmd
并尝试使用cygwin bash
做同样的事情。我得到类似的错误,但除了DXCstate.etl
,我没有看到任何其他错误。
我正在使用admin privelges运行终端,log.cmd
拥有755个权限。
$ ./log.cmd
Xperf: error: NT Kernel Logger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: DxTest: Cannot create a file when that file already exists. (0xb7).
Xperf: error: DxLogger: Cannot create a file when that file already exists. (0xb7).
The trace you have just captured "C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\gpuview\DXCState.etl" may contain personally identifiable information, including but not necessarily limited to paths to files accessed, paths to registry accessed and process names. Exact information depends on the events that were logged. Please be aware of this when sharing out this trace with other people.
Xperf: error: DxcStackLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: DxcLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: UMDLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: DXGILogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: Dx11Logger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: D3D10Level9Logger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: MFLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: OLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: XAMLLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: D2DLogger: Cannot create a file when that file already exists. (0xb7).
Xperf: error: D2DScenariosLogger: Cannot create a file when that file already exists. (0xb7).
$ ls
DXCState.etl* DxEtw.dll* EventsForStackTrace.txt* dota2/ GPUView.chm* GPUView.exe*
LDDMCore.man* log.cmd* plugins/ README.TXT* tplugins/ UMDEtw.man*
答案 0 :(得分:0)
如果查看log.cmd,您会看到每个记录器都与文件名相关联。例如,我们有这一行:
“%~dp0”.. \ Xperf -start DxcLogger -on%TRACE_DXC_MIN %% TRACE_LARGE_BUFFERS%-f DXC.etl
如果你可以“当该文件已存在时无法创建文件”错误,那么这意味着DXC.etl已经存在,这意味着以前的log.cmd调用没有干净地退出并且没有停止记录到该文件。您可能已使用Ctrl + C取消了批处理文件。它与Process Explorer或资源监视器不冲突,因为它们不会特别使用DXC.etl。
因此,重启机器以恢复良好状态,并警惕在工作中停止log.cmd。
或者,只需停止使用log.cmd即可。请改用wprui.exe。有关详细信息,请参阅此博客文章:
http://randomascii.wordpress.com/2013/04/20/xperf-basics-recording-a-trace-the-easy-way/