Share via


Enable Protocol Logging for POP3 and IMAP4

Applies to: Exchange Server 2010

You can configure protocol logging settings for POP3 and IMAP4 on an Microsoft Exchange Server 2010 Client Access server. Protocol logging isn't enabled by default. You can use protocol logging to review the POP3 and IMAP4 connections in your Exchange environment. This can be useful if you're troubleshooting issues related to POP3 or IMAP4 performance.

Protocol logging can be enabled or disabled using the Shell. Optionally, you can enable, disable, and modify protocol logging options by editing the Microsoft.Exchange.Pop3.exe.config and Microsoft.Exchange.Imap4.exe.config configuration files located on your Microsoft Exchange Server 2010 Client Access server.

For more information about POP3 and IMAP4 protocol logging, see Understanding Protocol Logging for POP3 and IMAP4.

Looking for other management tasks related to setting up POP 3 and IMAP4? Check out Managing POP3 and IMAP4.

Use the Shell to enable or disable protocol logging

You need to be assigned permissions before you can perform this procedure. To see what permissions you need, see the "POP3 and IMAP4" entry in the Client Access Permissions topic.

This example enables protocol logging for IMAP4.

Set-IMAPSettings -protocolLogEnable -true

This example enables protocol logging for POP3.

Set-POPSettings - protocolLogEnable -true

This example disables protocol logging for IMAP4.

Set-IMAPSettings -protocolLogEnable -false

This example disables protocol logging for POP3.

Set-POPSettings - protocolLogEnable -false

The settings will take effect as soon as you restart the service.

For more information about syntax and parameters for these cmdlets, see Set-ImapSettings and Set-PopSettings.

Use the POP3 and IMAP4 configuration files to enable, disable, or modify default protocol logging options

You need to be assigned permissions before you can perform this procedure. To see what permissions you need, see the "POP3 and IMAP4" entry in the Client Access Permissions topic.

  1. Open the configuration file for the protocol you want to enable, disable, or modify settings for in Notepad, as follows:

    • For POP3, open C:\Program Files\Microsoft\Exchange Server\ClientAccess\PopImap\ Microsoft.Exchange.Pop3.exe.config.
    • For IMAP4, open C:\Program Files\Microsoft\Exchange Server\ClientAccess\PopImap\ Microsoft.Exchange.Imap4.exe.config.
  2. Enable or disable protocol logging by changing the <appSettings> section as follows. Note that the parameter names in the <add key=../> section are case sensitive.

    1. To enable protocol logging, change the following line in the <appSettings> section from:

      <addkey="ProtocolLog" value="false" />
      

      to:

      <addkey="ProtocolLog" value="true" />
      
    2. To disable protocol logging, change the following line in the <appSettings> section from:

      <addkey="ProtocolLog" value="true" />
      

      to:

      <addkey="ProtocolLog" value="false" />
      
  3. If you want to change the default protocol logging settings, review the following table, which contains parameters that define how protocol logging works for POP3 and IMAP4. Then, modify the settings in the Microsoft.Exchange.Pop3.exe.config or Microsoft.Exchange.Imap4.exe.config configuration file.

    Parameters you can configure for protocol logging

    Parameter name Description

    AgeQuotaInHours

    This value defines how often the protocol log file will be re-created. By default, the value is set to 24.

    SizeQuota

    This value defines the size limit after which the protocol log will automatically be re-created. By default, the value is set to 10000000. However, if the file size doesn't exceed this value, the file will be re-created automatically at the time interval based on the value specified by the AgeQuotaInHours parameter.

    PerFileSizeQuota

    This value defines the byte file size above which a new file will be created. By default, this is set to 1000000. The protocol log file will create a new protocol log file every time that this value is exceeded.

  4. Save, and then close the Microsoft.Exchange.Pop3.exe.config file or the Microsoft.Exchange.Imap4.exe.config file.

  5. Restart the POP3 service or the IMAP4 service.

Other Tasks

After you configure protocol logging settings for POP3 and IMAP4, you may also want to consider: