How Office 365 uses PowerShell to query for message tracking

Source: Internet
Author: User

How to use PowerShell to track office365 messages

1. First link to Exchange Online management above

  

$UserCredential = get-= new-pssession-configurationname Microsoft.exchange-connectionuri https:// partner.outlook.cn/powershell-credential $UserCredential-authentication basic-allowredirection Import-pssession $Session

2. Query message tracking, export UTF-8 to CSV file

  

get-= $dateEnd. AddHours (-8) #目前时间之前的8个小时之内 $recipient="[email Protected]"  #导出收件人是 [email protected] User #自定义时间, convert time zone Get-messagetrace-startdate $ Datestart-enddate $dateEnd-recipientaddress $recipient | Select-object @{name='time'; E={[system.timezone]::currenttimezone.tolocaltime ($_ . Received)}}, Senderaddress, RecipientAddress, Subject, Status, Toip, FROMIP, Size, MessageID, Messagetraceid | Export-csv-encoding UTF8 D:\Only.csv

How Office 365 uses PowerShell to query for message tracking

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.