Applies to: Exchange Server 2007 SP3, Exchange Server
2007 SP2, Exchange Server 2007 SP1, Exchange Server 2007
Topic Last Modified: 2007-08-22
This topic explains how to configure the EdgeTransport.exe.config file to manage the anti-spam agent log files. By default, Microsoft Exchange Server 2007 logs all anti-spam agent activity in the %programfiles%\Microsoft\Exchange Server\TransportRoles\Logs\AgentLog directory. To filter the anti-spam agent logs, use the Get-AgentLog cmdlet. For more information, see Get-AgentLog.
The default configuration of the agent log files are as follows:
- Maximum size of the agent log directory: 250 MB
- Maximum size of a single agent log file: 10 MB
- Maximum age of log files: 30 days
Important: |
---|
Exchange 2007 Service Pack 1 (SP1) includes keys in the EdgeTransport.exe.config application configuration file that let you modify these default values. The release to manufacturing (RTM) version of Exchange 2007 does not read the keys that are documented in this topic. |
Modifying the EdgeTransport.exe.config File
All modifications of configuration options for managing agent log output must be made in the EdgeTransport.exe.config file that is located in the %programfiles%\Microsoft\Exchange Server\Bin directory. The EdgeTransport.exe.config file is an XML application configuration file that is associated with the EdgeTransport.exe file. EdgeTransport.exe and MSExchangeTransport.exe are the executable files that are used by the Microsoft Exchange Transport service. This service runs on every Hub Transport server and Edge Transport server. Changes that are saved to the EdgeTransport.exe.config file are applied after the Microsoft Exchange Transport service is restarted. The default value is enforced if either of the following conditions is true:
- A configuration option is missing.
- A configuration option is present and contains the default
value.
The following example shows the typical structure of the EdgeTransport.exe.config file:
Copy Code | |
---|---|
<configuration> <runtime> <gcServer enabled="true" /> </runtime> <appSettings> <add key=" Configuration Option " value=" Value " /> |
…
Copy Code | |
---|---|
</appSettings> </configuration> |
You can add new configuration options or modify
existing configuration options in the
<appSettings>
section. Many of the available
configuration options are not related to agent log output.
Configuration options that are not related agent log output are
outside the scope of this topic.
Agent Log Output Keys
Agent log output is managed by the following keys in the EdgeTransport.exe.config file:
Copy Code | |
---|---|
<add key="AgentLogEnabled" value="system.boolean" /> <add key="AgentLogMaxDirectorySize" value="system.int32" /> <add key="AgentLogMaxFileSize" value="system.int32" /> <add key="AgentLogMaxAge" value="system.timespan" /> |
By default, only the AgentLogEnabled
key
is present in the EdgeTransport.exe.config file. You must add all
other keys. The following table explains each key in more
detail.
Key | Value type | Description |
---|---|---|
|
System.Boolean |
By default, this key exists in EdgeTransport.exe.config. Valid
values for this key are |
|
System.Int32 |
By default, this key does not exist in EdgeTransport.exe.config. The value of this key specifies the maximum size, in bytes, of the AgentLog directory. When this value is exceeded, the oldest log file in the directory is deleted and a new log file is created. If this key is not specified, the default value is 250 MB, or 262144000 bytes (250*1024*1024) in Exchange 2007 RTM and Exchange 2007 SP1. |
|
System.Int32 |
By default, this key does not exist in EdgeTransport.exe.config. The value of this key specifies the maximum size, in bytes, of each log file in the directory. When a log file reaches the size specified, a new log file is created. If this key is not specified, the default is 10 MB, or 10485760 bytes (10*1024*1024) in Exchange 2007 RTM and Exchange 2007 SP1. |
|
System.TimeSpan |
By default, this key does not exist in EdgeTransport.exe.config. The value of this key specifies the maximum age limit of a given log file. When a log file exceeds the age limit, it is deleted. This key is of system type If this key is not specified, the default value is 30 days,
or |
Before You Begin
To perform this procedure, the account you use must be delegated the following:
- Member of the local Administrators group on the computer
For more information about permissions, delegating roles, and the rights that are required to administer Exchange 2007, see Permission Considerations.
Procedure
To add and configure the agent log output keys in the EdgeTransport.exe.config file
-
On the Hub Transport server or Edge Transport server on which you want to manage the agent log output, open the EdgeTransport.exe.config in an ASCII text editor such as Notepad. The EdgeTransport.exe.config file is located in the %programfiles%\Microsoft\Exchange Server\Bin directory.
-
Locate the
AgentLogEnabled
key. By default, the keys are listed in alphabetical order under<appsettings>
. -
Copy and paste the following keys under the
AgentLogEnabled
key:Copy Code <add key="AgentLogMaxDirectorySize" value="system.int32" /> <add key="AgentLogMaxFileSize" value="system.int32" /> <add key="AgentLogMaxAge" value="system.timespan" />
-
Verify that the
AgentLogEnabled
key is set totrue
, and add values for the other keys. -
When you have finished updating the EdgeTransport.exe.config file, save the file and close it.
-
You must restart the Microsoft Exchange Transport service before the configuration changes will take effect.
For More Information
For more information, see Get-AgentLog.