PowerTip: Use PowerShell to add ETW provider to a session


Summary: Use Windows PowerShell to add an ETW provider to a session.

Hey, Scripting Guy! Question How can I use Windows PowerShell to add an ETW provider to a session?

Hey, Scripting Guy! Answer Use the Add-NetEventProvider cmdlet and specify the name of the session and the provider. In the following example, first a net event session is created, and then the TCPIP ETW provider is added to the session:

PS C:\>New-NetEventSession -SessionName "Session01"

PS C:\> Add-NetEventProvider -Name "Microsoft-Windows-TCPIP" -SessionName  "Session01"

Comments (1)

  1. Jonathan says:

    Where does the picture of the labcoat guy come from?

Skip to main content