Purging -- DSN Messages Pending Submission Queue

Purging -- DSN Messages Pending Submission Queue

Post by ShadowFa » Fri, 21 May 2004 13:01:24

I froze the DSN Messages Pending Submission queue on my
EX2k3 box. In about two days it has collected 66,000
messages. (we only have 50 users and 1 exchange box)

Is there a way to programmatically delete these
messages ? Everytime I try to delete 10,000 at a time
the ESM mmc snap-in hangs.

I know i could unfreeze the queue and it would
subsquently create about 1000 queues to non-existent
domains and i would have to go in and manually delete the
messages from each of those queues.


Purging -- DSN Messages Pending Submission Queue

Post by Deji Akomo » Fri, 21 May 2004 13:25:31

@echo off
net stop smtpsvc
ren <path-to-Exchange-Install-folder\>badmail badmail_Old
mkdir <path-to-Exchange-Install-folder\>badmail
net start smtpsvc
rmdir <path-to-Exchange-Install-folder\>badmail_Old /Q /S

Put that in a Batch File. Use it once a day.

Since you are on E2K3, you should seriously consider using Recipient Filters
and filter names that don't exist in your Directory.



MVP - Directory Services
www.readymaids.com - got SPAM problems?
Do you now realize that Today is the Tomorrow you were worried about
Yesterday? -anon