Windows IT Pro is the authoritative and independent resource for windows nt, windows 2000, windows 2003, windows xp. Features a collection of resources and magazines for windows IT professionals.
  
  
  Advanced Search 


September 2003

Clearing a Blocked Exchange SMTP Message Queue


RSS
Subscribe to Windows IT Pro | See More Exchange 2000 Server Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!

I'm having a major problem with our Microsoft Exchange 2000 Server system. As of last night, the Exchange server suddenly stopped delivering incoming and outgoing messages. Outgoing messages leave users' Outboxes and appear to transmit fine but are never received by recipients (even when sent to the sending user's own mailbox). Incoming messages from external senders don't bounce and seem to be received by the server but never show up in our users' Inboxes. Where are the messages going, and what can I do to straighten out the situation?

The problem you describe is all too familiar to me. The cause is most likely a stuck message in the SMTP queue folder. The Exchange server's Message Transfer Agent (MTA) occasionally (and for reasons unbeknownst to me and not adequately described anywhere by Microsoft) chokes on a message and ends up spinning its metaphorical wheels. Theoretically, Exchange should be able to deal with bad messages in a more graceful manner but unfortunately fails to do so in some cases.

To test for and resolve this situation, first navigate to the SMTP queue folder on your Exchange server (typically the C:\program files\exchsrvr\mailroot\vsi 1\queue folder—vsi 1 stands for SMTP virtual server instance 1—unless you have multiple SMTP virtual server instances on the server). As Figure 1 shows, this folder will probably contain several files beginning with NTFS and ending in an .eml extension (which stands for—you guessed it—email). These files are queued SMTP messages that the Exchange server needs to process. One of the messages—in most cases, the oldest one—is probably causing the difficulty. By using Windows Explorer's Detail View to view the folder, you can determine the order in which Exchange is processing messages. The first message awaiting processing (i.e., the message with the earliest date and time) is the most likely culprit. If the machine you use to view the queue folder is running Microsoft Outlook or Outlook Express, you can use either program to view the content of the queued messages; otherwise, you can use Notepad or a text editor.

The next step is to delete the message from the queue. First, make a backup copy of the message in case it isn't the culprit. Second, stop the Exchange services on the server, or the system likely will report the file as being in use when you attempt to delete it. Exchange System Manager (ESM) provides a way to delete individual messages from the queue (as the Microsoft article "HOW TO: Delete Messages from Queues in Exchange 2000 Server" at http://support.microsoft.com/?kbid=314327 explains). However, I typically use the Windows Explorer method I just described to identify and delete the offending message because Windows Explorer's Detail view lets you observe each file's date and timestamp, making identifying the oldest file easy. Also, you can easily see and open the message—in my experience, ESM sometimes fails to display the problematic message in this type of situation.

After you successfully delete the message, restart the Exchange services. At this point, Exchange should start delivering messages. If it doesn't, you've probably deleted the wrong message. Restore the message you copied, then pick the next-oldest message and try again, repeating the process until you find the message that's causing the problem.

You should always begin any troubleshooting exercise by examining your Exchange server's event logs and researching relevant articles in the Microsoft Knowledge Base to determine whether they apply to your situation. However, in my experience, none of the dozens of Microsoft articles about stuck messages in the SMTP queue have been helpful in the situation you describe; I've needed to take the actions I describe above to free the queue and start messages flowing again.

End of Article



Reader Comments
You are right on the money! I had this problem with my Exchange 5.5 Server 2 days ago! It took me a while to figure out the solution though, I wish I had read this article first!

maefly April 09, 2004


I have the same problem on my 5.5 server. Is there any way to delete a message on this platform?

The solution above only applies to exchange 2000 or newer. I cant find the queue on my 5.5 server.

Mattias Nordin April 30, 2004


I have been experiencing the same trouble, in one week my SMTP (Exchange 2K) stuck 3 times, is there a way to avoid this?? Some kind of patch?? It´s very annoying and dangerous, since i work in a lawyer office and the e-mails has a crucial importance.

Nivaldo Soraggi May 18, 2004


Great article. Thanks!
I made a bat file that takes care of the problem and thought I would share it. Get it here:
http://www.c-online.dk/download/cbemq.zip

Rasmus Carstensen June 24, 2004


Ya I agree nice article.........just one Q for Rasmus I got the bat file from the link but how and where do I put it.....

matrix July 07, 2004


Hi ! I tried running the same script on my exchange server however no message got moved to the said folder and queue is still the same. I feel that my exchange is being used by spammers for relaying purpose and that's why I can see huge queues. Could anyone kindly guide me how to track a mail in SMTP queue to know its original sender's IP, username etc. and How can I stop relaying for external world.
1. In the Defualt virtual server--access-->Relay I have allowed only my LAN to relay and selected Allow all computers which are able to authenticate

Please advise I am really stuck.

Vivek

vivekkhare August 11, 2004 (Article Rating: )


Have spent hours trawling the internet for confirmation that I could delete my culprit EML file without adverse effect. Finally someone's confirmed it. Thanks and boo-sucks to Microsoft for completely avoiding any useful information on this problem in their knowledge base.

jinedin November 19, 2004 (Article Rating: )


good article, but as I'm new to exchange 2000 I can't find the services I should stop. Can you please give me a hand with this. Thanks !!!

moony December 06, 2005 (Article Rating: )


great but as I'm new to exchange 2000 I can't find the services I should stop, can you give me a hand with this? Thanks

moony December 06, 2005 (Article Rating: )


You must log on before posting a comment.

If you don't have a username & password, please register now.




Top Viewed ArticlesView all articles
Friday at PASS Europe 2006

Kevin talks about the closing day of the event and shares a funny Microsoft film. ...

Escape From Yesterworld

Kevin points you to the funniest SQL Server website ever! ...

PsExec

This freeware utility lets you execute processes on a remote system and redirect output to the local system. ...


Exchange Server and Outlook Whitepapers Protecting (You and) Your Data with Exchange Server 2007

StoreVault SnapManagers for Microsoft Exchange and SQL Server

Related Events Storage Consolidation for Your Microsoft Applications: Reducing Cost and Complexity

The Myths & Truths of Email Management with SharePoint

Top 10 Email Security Challenges and Solutions

Check out our list of Free Email Newsletters!

Exchange Server and Outlook eBooks Spam Fighting and Email Security for the 21st Century

Understanding and Leveraging Code Signing Technologies

The Expert's Guide for Exchange 2003: Preparing for, Moving to, and Supporting Exchange Server 2003

Related Exchange Server and Outlook Resources Become a VIP member of the Windows IT Pro community!
Get it all with the VIP CD and VIP access. A $500+ value for only $279!

Subscribe to Windows IT Pro!
Solve your toughest technical problems with our experts and access 10,000 + articles online. 30% off

Monthly Online Pass - Only $5.95!
Get instant access to 10,000+ articles from Windows IT Pro Magazine!

TechNet Virtual Labs
Evaluate and test Microsoft's newest products.

Exchange & Outlook UPDATE eNewsletter
News, strategies, products, and developments in Exchange Server and Outlook messaging.

Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro Windows Dev Pro IT Job Hound ITTV
IT Library Technology Resource Directory Connected Home Windows Excavator Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 Copyright © 2008 Penton Media, Inc., All rights reserved. Terms and Use | Privacy Statement | Reprints and Licensing