Monday, October 21, 2013

What cmdlet might you use to write to an event log?

What cmdlet might you use to write to an event log?

get-command -verb write -noun eventlog
Or if you weren’t sure about the noun, use a wildcard:
help *log
PS C:\Users\m1024032> help *log

Name                              Category  Module                    Synopsis                                       
----                              --------  ------                    --------                                       
Clear-EventLog                    Cmdlet    Microsoft.PowerShell.M... Deletes all entries from specified event log...
Get-EventLog                      Cmdlet    Microsoft.PowerShell.M... Gets the events in an event log, or a list o...
Limit-EventLog                    Cmdlet    Microsoft.PowerShell.M... Sets the event log properties that limit the...
New-EventLog                      Cmdlet    Microsoft.PowerShell.M... Creates a new event log and a new event sour...
Remove-EventLog                   Cmdlet    Microsoft.PowerShell.M... Deletes an event log or unregisters an event...
Show-EventLog                     Cmdlet    Microsoft.PowerShell.M... Displays the event logs of the local or a re...
Write-EventLog                    Cmdlet    Microsoft.PowerShell.M... Writes an event to an event log.                

 

Featured Posts

Adding Accesspolicy to KeyVault for Service Principal Using Portal and Powershell

  Scripts path : https://drive.google.com/drive/folders/1sbBpnVFgXhUIXLdf2E9heyWDeU2f9427?usp=sharing  Adding Accesspolicy to KeyVault for S...