Udostępnij za pośrednictwem


How to collect SCVMM traces

In order to diagnose a failure scenario, it is normally required to reproduce the issue and collect traces at the same time.

Here are the instructions on how to collect the traces:

From what computer should I collect the trace?

  • If it’s a console crash issue,
    • please collect the traces from both the computer where you run admin console, and your VMM Server.
  • If it’s an “Add Hosts” issue,
    • please collect the traces from the VMM server;
  • If it’s a host status (Needs Attention) or VM issue,
    • please collect the traces from both the VMM server and the host in question. 
  • If it's self-service portal issue,
    • please collect the traces from the Web server and the VMM server

 

What are the steps to collect traces?

@echo off
echo ODS control flags - only trace with set flags will go to ODS

if (%1)==() goto :HELP
if (%1)==(-?) goto :HELP
if (%1)==(/?) goto :HELP

echo Setting flag to %1...
reg ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Tracing\Microsoft\Carmine" /v ODSFLAGS /t REG_DWORD /d %1 /f
echo Done.
goto :EXIT

:HELP
echo Usage: odsflags [flag], where flag is
echo TRACE_ERROR = 0x2,
echo TRACE_DBG_NORMAL = 0x4,
echo TRACE_DBG_VERBOSE = 0x8,
echo TRACE_PERF = 0x10,
echo TRACE_TEST_INFO = 0x20,
echo TRACE_TEST_WARNING = 0x40,
echo TRACE_TEST_ERROR = 0x80,

:EXIT

  • Save the following code into a text file and name it as "odson.reg":

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Tracing\Microsoft\Carmine]
"ODS"=dword:00000001

  • Save the following code into a text file and name it as "odsoff.reg":

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Tracing\Microsoft\Carmine]
"ODS"=dword:00000000

  • Copy the above three files onto your VMM server, your host in question and your Web server (if it's a self-service portal issue).
  • In a command window on the machine that you want to capture VMM tracing, run “odson.reg” and “odsflags.cmd 255”. (If you need to collect traces for both VMM Server and the host or the Web server, make sure to run these commands on all computers.)
  • Open DebugView and run it as administrator, make sure that in its Capture menu, you have both "Capture Win32" and "Capture Global Win32" checked. You should be able to see tracing from the VMM components showing up in the DebugView. (If you need to collect traces for both VMM Server and the host, make sure to do these steps on all computers.)
  • Restart vmmservice on VMM server with “net stop vmmservice” and “net start vmmservice”.
  • Restart the agent service on the host with “net stop vmmagent” and “net start vmmagent”.
  • Restart the IIS service on the Web server with "iisreset".
  • Reproduce the issue that you found.
  • Save the output from the DebugView to a text file and email it to the people who can help you diagnose the issue.
  • Don't forget to turn off the tracing after you are done collecting by running "odsoff.reg" on the machine.

 

Thanks for reading!

Cheng