Know How to Run Get-MessageTrackingLog cmdlet in Exchange?
The Get-MessageTrackingLog
cmdlet is used to retrieve message tracking logs in Microsoft Exchange Server. Here’s how to run the cmdlet:
- Open the Exchange Management Shell by running it as an administrator.
- Use the
Get-MessageTrackingLog
cmdlet with the appropriate parameters to retrieve the message tracking logs. The available parameters include:Start
: Specifies the start time of the logs to retrieve.End
: Specifies the end time of the logs to retrieve.Sender
: Specifies the email address of the message sender.Recipients
: Specifies the email addresses of the message recipients.MessageSubject
: Specifies the subject of the message.For example, to retrieve the message tracking logs for all messages sent between 9:00 AM and 10:00 AM on February 1, 2023, run the following command:
Get-MessageTrackingLog -Start “2/1/2023 9:00:00 AM” -End “2/1/2023 10:00:00 AM” - If you want to export the results to a CSV file, you can use the
Export-Csv
cmdlet. For example, to export the results to a CSV file named “MessageTrackingLogs.csv”, run the following command:
Get-MessageTrackingLog -Start “2/1/2023 9:00:00 AM” -End “2/1/2023 10:00:00 AM” | Export-Csv -Path “C:\Logs\MessageTrackingLogs.csv” -NoTypeInformation
This will export the message tracking logs to a CSV file located in the “C:\Logs” folder.