Export (0) Print
Expand All

How to Configure Connectivity Logging

 

Applies to: Exchange Server 2007 SP3, Exchange Server 2007 SP2, Exchange Server 2007 SP1, Exchange Server 2007

Topic Last Modified: 2007-06-06

This topic explains how to use the Exchange Management Console and the Exchange Management Shell to configure connectivity logging in Microsoft Exchange Server 2007.

noteNote:
Any connectivity log settings that are configurable by using the Exchange Management Console are available only in Microsoft Exchange Server 2007 Service Pack 1 (SP1). All connectivity logging settings are configurable by using the Exchange Management Shell in Exchange 2007 SP1 and in the release to manufacturing (RTM) version of Microsoft Exchange Server 2007.

Connectivity logging records the connection activity of the outgoing message delivery queues that exist on computers that have the Hub Transport server role or Edge Transport server role installed. The purpose of the connectivity log is not to track the transmission of individual e-mail messages. The connectivity log tracks the connection activity from the sending queue to the destination Mailbox server, smart host, or domain.

To perform the following procedures, the account you use must be delegated the following:

  • Exchange Organization Administrator role

To perform the following procedures on a computer that has the Edge Transport server role installed, you must log on by using an account that is a member of the local Administrators group on that computer.

For more information about permissions, delegating roles, and the rights that are required to administer Exchange 2007, see Permission Considerations.

By default, connectivity logging is disabled on all Exchange 2007 computers that have the Hub Transport server role or Edge Transport server role installed.

noteNote:
You can enable or disable connectivity logging by using the Exchange Management Console only in Exchange 2007 SP1.

  1. Open the Exchange Management Console. Perform one of the following steps:

    • On a computer that has the Edge Transport server role installed, select Edge Transport, and then in the action pane, click the Properties link that is directly under the server name.
    • On a computer that has the Hub Transport server role installed, in the console tree, expand Server Configuration, and select Hub Transport. In the action pane, click the Properties link that is directly under the server name.
  2. In the Properties page, click the Log Settings tab.

  3. In the Connectivity log section, perform one of the following steps:

    • Select Enable connectivity logging to enable connectivity logging.
    • Clear Enable connectivity logging to disable connectivity logging.
  4. Click Apply to save changes and remain in the Properties page, or click OK to save changes and exit the Properties page.

  • Run the following command:

    Set-TransportServer <Identity> -ConnectivityLogEnabled <$true | $false>
    

    For example, to enable connectivity logging on an Exchange 2007 computer that is named Exchange01, run the following command:

    Set-TransportServer Exchange01 -ConnectivityLogEnabled $true
    

By default, the connectivity log files are stored in the C:\Program Files\Microsoft\Exchange Server\TransportRoles\Logs\Connectivity directory. The directory must be local to the Exchange 2007 computer.

noteNote:
You can configure the location of the connectivity log files by using the Exchange Management Console only in Exchange 2007 SP1.

  1. Open the Exchange Management Console. Perform one of the following steps:

    • On a computer that has the Edge Transport server role installed, select Edge Transport, and then in the action pane, click the Properties link that is directly under the server name.
    • On a computer that has the Hub Transport server role installed, in the console tree, expand Server Configuration, and select Hub Transport. In the action pane, click the Properties link that is directly under the server name.
  2. In the Properties page, click the Log Settings tab.

  3. In the Connectivity log section, click Browse next to Connectivity log path.

  4. In the Browse for folder window, browse to the new location where you want to store the connectivity log files. If you want to create a new folder, select a parent folder, click Make New Folder, and then type the name of the new folder. After you make your folder selection, click OK to close the Browse for folder window.

  5. Click Apply to save changes and remain in the Properties page, or click OK to save changes and exit the Properties page.

  • Run the following command:

    Set-TransportServer <Identity> -ConnectivityLogPath <LocalFilePath>
    

    For example, to change the location of the connectivity log file to C:\Connectivity on an Exchange 2007 computer that is named Exchange01, run the following command:

    Set-TransportServer Exchange01 -ConnectivityLogPath "C:\Connectivity"
    

If you set the value of the ConnectivityLogPath parameter to $null, you effectively disable connectivity logging. However, if you set the value of the ConnectivityLogPath parameter to $null when the value of the ConnectivityLogEnabled attribute is $true, you will generate event log errors. The preferred method to disable connectivity logging is to use the ConnectivityLogEnabled parameter with the Set-TransportServer cmdlet.

When you change the location of the connectivity log directory, this change does not copy any existing log files from the old directory to the new directory. The new connectivity log directory is active almost immediately after the configuration change, but any existing log files are left in the old directory.

The following permissions are required on the connectivity log directory:

  • Administrator: Full Control
  • System: Full Control
  • Network Service: Read, Write, and Delete Subfolders and Files

By default, the Microsoft Exchange Transport service uses the security credentials of the Network Service user account to create the new connectivity log directory and apply the correct permissions as follows:

  • If the new connectivity log directory does not already exist, and the Network Service account has the rights necessary to create folders and apply permissions at the new location, the new connectivity log directory is created and the correct permissions are applied to the new directory.
  • If the new connectivity log directory already exists, the existing folder permissions are not checked.

Whenever you move the connectivity log directory by using the ConnectivityLogPath parameter with the Set-TransportServer cmdlet, it is a good idea to verify the new connectivity log directory and to make sure that the new directory has the correct permissions applied to it. If your change to the connectivity log directory is not successful, you can create the new connectivity log directory and apply the correct permissions to it before you use the ConnectivityLogPath parameter with the Set-TransportServer cmdlet.

By default, the maximum size for each connectivity log file is 10 MB. When a connectivity log file reaches its maximum size, Exchange 2007 opens a new connectivity log file. This process continues until either of the following conditions is true:

  • The connectivity log directory reaches its specified maximum size. For more information about how to change the maximum size of the connectivity log directory, see "Configuring the Maximum Size of the Connectivity Log Directory" later in this topic.
  • A connectivity log file reaches its specified maximum age. For more information about how to change the maximum age for a connectivity log file, see "Configuring the Maximum Age for the Connectivity Log Files" later in this topic.

After the maximum size or age limit is reached, circular logging deletes the oldest connectivity log files.

  • Run the following command:

    Set-TransportServer <Identity> -ConnectivityLogMaxFileSize <FileSize>
    

    For example, to set the maximum size of a connectivity log file to 20 MB on an Exchange 2007 computer that is named Exchange01, run the following command:

    Set-TransportServer Exchange01 -ConnectivityLogMaxFileSize 20MB
    

When you enter a value for the ConnectivityLogMaxFileSize parameter, qualify the value with one of the following units:

  • B (bytes)
  • KB (kilobytes)
  • MB (megabytes)
  • GB (gigabytes)
  • TB (terabytes)

Unqualified values are treated as bytes. The value of the ConnectivityLogMaxFileSize parameter must be less than or equal to the value of the ConnectivityLogMaxDirectorySize parameter. The valid input range for either parameter is 1 to 9223372036854775807 bytes.

By default, the maximum size for the whole connectivity log directory is 250 MB. Circular logging deletes the oldest connectivity log files when either of the following conditions is true:

  • The connectivity log directory reaches its specified maximum size.
  • A connectivity log file reaches its specified maximum age.
noteNote:
By default, the transport logging process has a logging level value of 0 (Lowest). If you want Microsoft Exchange to write an event log entry when circular logging removes a log file, you must change the logging level value of the transport logging process to 5 (Maximum) or 7 (Expert). For more information, see How to Change Logging Levels for Exchange Processes.

  • Run the following command:

    Set-TransportServer <Identity> -ConnectivityLogMaxDirectorySize <DirectorySize>
    

    For example, to set the maximum size of the connectivity log directory to 400 MB on an Exchange 2007 computer that is named Exchange01, run the following command:

    Set-TransportServer Exchange01 -ConnectivityLogMaxDirectorySize 400MB
    

Unqualified values are treated as bytes. The value of the ConnectivityLogMaxFileSize parameter must be less than or equal to the value of the ConnectivityLogMaxDirectorySize parameter. The valid input range for either parameter is 1 to 9223372036854775807 bytes.

By default, the maximum age for any connectivity log file is 30 days. Circular logging deletes the oldest connectivity log files if either of the following conditions is true:

  • The connectivity log directory reaches its specified maximum size.
  • A connectivity log file reaches its specified maximum age.
noteNote:
By default, the transport logging process has a logging level value of 0 (Lowest). If you want Microsoft Exchange to write an event log entry when circular logging removes a log file, you must change the logging level value of the transport logging process to 5 (Maximum) or 7 (Expert). For more information, see How to Change Logging Levels for Exchange Processes.

  • Run the following command:

    Set-TransportServer <Identity> -ConnectivityLogMaxAge <Age>
    

    For example, if you want to change the maximum age of a connectivity log file to 45 days on an Exchange 2007 computer that is named Exchange01, run the following command:

    Set-TransportServer Exchange01 -ConnectivityLogMaxAge 45.00:00:00
    

To specify an age value, enter it as a time span, as follows: dd.hh:mm:ss, where d = days, h = hours, m = minutes, and s = seconds. The valid input range for this parameter is 00:00:00 to 24855.03:14:07. Setting the value of the ConnectivityLogMaxAge parameter to 00:00:00 prevents the automatic removal of connectivity log of files because of their age.

For detailed syntax and parameter information, see Set-TransportServer.

For more information about connectivity logging, see Managing Connectivity Logging.

To ensure that you are reading the most up-to-date information and to find additional Exchange Server 2007 documentation, visit the Exchange Server TechCenter.
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft