Exchange Powershell Tip #13
Exchange Powershell Tip #13
How do I see values of all the parameters from the Exchange Cmdlet? (Powershell Please show me everything out of that cmdlet )
Usually any Exchange cmdlet shows values of very basics and important properties in the output if you don’t specify anything specific that you want or more broader if you don’t specify to get everything.
For Example, when you type any cmdlet like, Get-RemoteDomain, Get-Mailbox MailboxName or Get-ExchangeServer. It shows you the limited parameters which fits in the table format on the screen.
Now if you want to see all the parameter in list format you can pipe the output to list format with | Format-List or | FL
For Example, Get-RemoteDomain | Format-List, Get-Mailbox MailboxName | FL or Get-ExchangeServer | FL
Now what if there are multiple values or lines in the output, eg if you get multiple lines of tracking log while tracking a message and want to see everything that a sender sent out on a day, Oct 18 2016. You can run below cmdlet to get the result.
Get-MessageTrackingLog -sender email@example.com -resultsize unlimited -start 10/18/2016 –end 10/19/2016 | FL
Though it would be difficult to see and manipulate everything on the screen. If you are interested on learning more around Message Tracking and how to export output with recipient information etc… then get going with Paul’s site, he has some great tutorials. – http://exchangeserverpro.com/exchange-2010-message-tracking-log-search-powershell/
Now the main an my favorite part which I am trying to emphasize in this Tip. Use Out-GridView to have more fun with PowerShell. As the name says, Pipe the Output to GridView and then do manipulation there to what you want by filtering individual parameter values with funtatsic way . Though keep in mind you have to Select everything with Select * before you pipe the output to Grid View.
Get-MessageTrackingLog -sender firstname.lastname@example.org -resultsize unlimited -start 10/18/2016 –end 10/19/2016 | Select * | Out-GridView
You can search anything here in the top Filter box or add any Criteria based filter too…
You can look at the value of any property which is hard to see and map with all the entries in the list view or tabular view while you are doing in-depth troubleshooting in the small PowerShell window/view.
For example RecipientStatus in the tracking log can show you some valuable information like if message is moved to any folder by an Outlook rule in the mailbox. For example, in below screen RecipientStatus shows “SentFromMe-Folder” which is the folder name where message is actually moved to and user says he missing that message in his Inbox but it is actually in another folder of the mailbox moved by an outlook rule.