16 August 2009

SMTP queue

I spend a lot of time surfing various Exchange-related message boards, trying to figure out what the latest issues are. One of the topics that I see posted the most often concerns flooded SMTP queues. There are many reasons why SMTP queues become clogged, but the primary reason is spam.If your Exchange Server is configured to act as an open mail relay, then your SMTP queues will be constantly filled with thousands of messages. Likewise, if someone is simply bombarding your organization with spam, the queues will tend to fill up as well. Not only does the in-bound spam consume space in the queue, but if your server is configured to generate non-delivery reports (NDRs) when spam is sent to an invalid e-mail address within your organization, then those NDRs will also consume space within the queue. It is completely normal for your SMTP queues to have messages in them. Normally these messages won't cause a problem. What does cause a problem, though, is when messages come into the queue faster than they can be processed and the mail flow never eases up enough to allow the server time to catch up. In this situation, it's only a matter of time before the disk volume housing the SMTP queues runs out of space.To understand how to combat SMTP queue flooding problems, you need to understand about the anatomy of an SMTP queue. As you probably know, just about everything in Exchange is database driven. This isn't the case with the SMTP queues. An SMTP queue is nothing more than a folder on the hard disk. Each message within the queue exists as an individual file within the folder.By default, the SMTP queue is located at \Program Files\exchsrvr\Mailroot\vsi 1\. This folder contains three sub folders: BadMail, Pickup and Queue. When a message is initially received, it is placed in the PickUp folder. Exchange then determines whether or not it knows what to do with the message. If the message is valid, it is placed in