Moving Transport Queue In Exchange 2007…

All servers running exchange 2003 has smtp queues. This behaviour has been changed in 2007, with only the transport servers having a mail queue. If you have an edge server in your environment, then both your edge and hub servers have a transport queue, which is an ESE database named Mail.Que If you don’t have…

All servers running exchange 2003 has smtp queues. This behaviour has been changed in 2007, with only the transport servers having a mail queue. If you have an edge server in your environment, then both your edge and hub servers have a transport queue, which is an ESE database named Mail.Que

If you don’t have an edge, the transport queues will be present only in the hub servers. The default location of the transport queue database is in System driveProgram FilesMicrosoftExchange ServerTransport RolesDataQueue.

The location will have an ESE database named Mail.Que, a temporary edb file, log files, checkpoint file and reserved log files. It is ideal to move the queue database to a drive which has more space, as it will stop message delivery if the drive runs out of space.

There are two ways to move the database to a different drive.

1. Edit the EdgeTransport.exe Config file.

Navigate to exchange 2007 bin directory (system driveProgram FilesMicrosoftExchange ServerBin, assuming the default location).

Open the edgetransport.exe.config file using notepad.

Edit the location for QueueDatabasePath and QueueDatabaseLoggingPath to your desired location and save. The transport service has to be restarted for the change to take effect. The queue from the original location is NOT moved, it only creates a new database in the new location.

2. Use Move-TransportDatabase script in exchange scripts folder.

Launch Exchange Shell and run the following command.

.Move-TransportDatabase.ps1 –QueueDatabasePath “d:Queue” –QueueDatabaseLoggingPath “d:QueueLogs”

The queue database and associated files will be moved from original location to the new one and the transport service is restarted automatically as part of the script, which is a good feature.

Moral : Use the script to make things easier!

2 Comments

  1. Very helpful script with one small caveat, if you're going with option 1. Make sure when you move the files over to the new location that the owner is "Network Services" with full control. Otherwise the transport service will not start, complaining about read/write access.

  2. Very informative. Thanks

Leave a Reply

Your email address will not be published. Required fields are marked *