Any suggestions? Export (0) Print
Expand All
Collapse the table of content
Expand the table of content
Expand Minimize

Get-AgentLog

 

Applies to: Exchange Server 2016

This cmdlet is available only in on-premises Exchange Server 2016.

Use the Get-AgentLog cmdlet to parse log files that you specify as parameters and collect raw statistics from the filtering that anti-spam agents apply during a time period that you specify.

Get-AgentLog [-EndDate <DateTime>] [-Location <LocalLongFullPath>] [-StartDate <DateTime>] [-TransportService <Hub | Edge | FrontEnd | MailboxSubmission | MailboxDelivery>]

This example returns a report that has statistics collected between 09:00 (9 A.M.), January 4, 2015 and 18:00 (6 P.M.), January 8, 2015 in the Front End Transport service.

Get-AgentLog -StartDate "01/04/2015 9:00:00 AM" -EndDate "01/08/2015 6:00:00 PM" -TransportService FrontEnd

You need to be assigned permissions before you can run this cmdlet. Although all parameters for this cmdlet are listed in this topic, you may not have access to some parameters if they're not included in the permissions assigned to you. To see what permissions you need, see the "Anti-spam features" entry in the Anti-spam and anti-malware permissions topic.

 

Parameter Required Type Description

EndDate

Optional

System.DateTime

The EndDate parameter specifies the end date of the date range.

Use the short date format that's defined in the Regional Options settings on the computer where you're running the command. For example, if the computer is configured to use the short date format mm/dd/yyyy, enter 09/01/2015 to specify September 1, 2015. You can enter the date only, or you can enter the date and time of day. If you enter the date and time of day, enclose the value in quotation marks ("), for example, "09/01/2015 5:00 PM".

Location

Optional

Microsoft.Exchange.Data.LocalLongFullPath

The Location parameter specifies the directory that contains the log files that you can use to build usage reports. The default path is %ExchangeInstallPath%TransportRoles\Logs\AgentLog. You need to enclose the file path in quotation marks (").

StartDate

Optional

System.DateTime

The StartDate parameter specifies the start date of the date range.

Use the short date format that's defined in the Regional Options settings on the computer where you're running the command. For example, if the computer is configured to use the short date format mm/dd/yyyy, enter 09/01/2015 to specify September 1, 2015. You can enter the date only, or you can enter the date and time of day. If you enter the date and time of day, enclose the value in quotation marks ("), for example, "09/01/2015 5:00 PM".

TransportService

Optional

Microsoft.Exchange.Data.TransportService

The TransportService parameter specifies the transport service that you want to view or modify. Valid values for this parameter are:

  • Hub for the Transport service on Mailbox servers.

  • MailboxSubmission for the Mailbox Transport Submission service on Mailbox servers.

  • MailboxDelivery for the Mailbox Transport Delivery service on Mailbox servers.

  • FrontEnd for the Front End Transport service on Mailbox servers.

  • Edge on Edge Transport servers.

To see the input types that this cmdlet accepts, see Cmdlet Input and Output Types. If the Input Type field for a cmdlet is blank, the cmdlet doesn’t accept input data.

To see the return types, which are also known as output types, that this cmdlet accepts, see Cmdlet Input and Output Types. If the Output Type field is blank, the cmdlet doesn’t return data.

 
Show:
© 2016 Microsoft