NT Kernel Logger Constants
Use the following constants to identify the NT Kernel Logger session.
Constant | Description |
---|---|
SystemTraceControlGuid | The control GUID for the NT Kernel Logger event tracing session. |
KERNEL_LOGGER_NAME | The name of the NT Kernel Logger event tracing session. |
The NT Kernel Logger session is the only session that can accept events from kernel event providers. The NT Kernel Logger session does not accept events from other providers. If you want to capture kernel events and events from other providers, you must use two separate sessions and the consumer would need to merge the events from the log files to provide end-to-end results.
ETW uses the DEFINE_GUID macro to define GUIDs. To use SystemTraceControlGuid in your code, you must include #define INITGUID before including Evntrace.h. The compiler will then turn the DEFINE_GUID into a constant GUID.
The following values define the possible class GUIDs for kernel events that an NT Kernel Logger session can trace. You can pass the class GUIDs to the SetTraceCallback function to set up special processing for each event class.
Class | GUID |
---|---|
ALPC |
|
DiskIo |
|
HWConfig and SystemConfig |
|
FileIo |
|
Image |
|
PageFault_V2 |
|
PerfInfo |
|
Process |
|
Registry |
|
SplitIo |
|
TcpIp |
|
Thread |
|
UdpIp |
|
Remarks
To use the GUIDs, copy the GUID definitions that you want to use to your source code. You must include #define INITGUID before the definitions you include in your source code, so the compiler will turn the DEFINE_GUID into a constant GUID. For example,
#define INITGUID
DEFINE_GUID ( /* 3d6fa8d1-fe05-11d0-9dda-00c04fd7ba7c */
ThreadGuid,
0x3d6fa8d1,
0xfe05,
0x11d0,
0x9d, 0xda, 0x00, 0xc0, 0x4f, 0xd7, 0xba, 0x7c
);
DEFINE_GUID ( /* 3d6fa8d0-fe05-11d0-9dda-00c04fd7ba7c */
ProcessGuid,
0x3d6fa8d0,
0xfe05,
0x11d0,
0x9d, 0xda, 0x00, 0xc0, 0x4f, 0xd7, 0xba, 0x7c
);
As an alternative, you can define the constant GUID for the GUID definitions yourself. For example,
static const GUID ThreadGuid =
{ 0x3d6fa8d0, 0xfe05, 0x11d0, { 0x9d, 0xda, 0x00, 0xc0, 0x4f, 0xd7, 0xba, 0x7c } };