Exchange Server Share

… Information sharing on Exchange Server …

Exchange Powershell Tip #07

Exchange Powershell Tip #07

How to set Event Logging Level (Diagnostic Logging) on all or filtered Exchange servers in bulk?

While troubleshooting Exchange issue you might need to set Diagnostic Logging level by increasing information level of the Event Logs. For example, if you want to set the diagnostic logging for “MSExchangeActiveSync\Requests” to High on all (or filtered) Exchange servers in your environment, then you can use below cmdlet…

$Test = Get-ExchangeServer
$Test | ForEach{Set-EventLoglLvel “$_\MSExchange ActiveSync\Requests” -Level High}

Verity that it is set on all the severs using this…

$Test = Get-ExchangeServer
$Test | ForEach{Get-EventLoglLvel “$_\MSExchange ActiveSync\Requests”}

Here is the sample output:

ExShellTip7-EventLogLevel

You can filter the list of servers with Get-ExchangeServer cmdlet, like Get-ExchangeServer ABC* will set just servers starting with name “ABC”. You can use more complex filtering based on your need…

Here is the reference of available Event Log Levels:

0 – Lowest
1 – Low
3 – Medium
5 – High
7 – Expert

==> Get All Exchange Powershell Tips from the Archive Here<==

Advertisements

Written by Amit Tank

May 28, 2016 at 5:00 pm

%d bloggers like this: