Some days ago, I noticed that I have a bunch of yet unseen error messages about undeliverable e-mail in my daily.out log file: Postqueue was unable to send mail to myusername@mymachinename.local?! Running no mail services on my machine, the situation was quickly clear -- developing php-baesd websites locally, I have tested a form mailer with some wrong parameters, so the actual mail server was not found. My research to get rid of these mails brought up an easy command (mailq -q) which, when run as root, would theoretically flush any local mail and thereby delete the undeliverable. The only problem was that when I tried it, the command only produced error messages about the mail system being down.
The final solution was as easy as the command itself. Simply open up another Terminal session and start up sendmail temporarily by typing sudo sendmail. The prompt will stay empty because sendmail waits for its input, but that doesn't matter at this time.
Switch back to your first session, execute the command sudo mailq -q, and your local mailqueue will be emptied. End this session, switch to the one which has sendmail running, type Control-C to stop sendmail, and you are done.
Mac OS X Hints
http://hints.macworld.com/article.php?story=20061128094353786