Noel Jones | 4 Jul 05:48

Re: How to backhole mail?

Srdan Dukic wrote:
> Hi,
> 
> For one of my projects I'm setting up a server to test the total
> number of SMTP connections that our postfix server can handle. I am
> trying to isolate the first part of the smtp server transaction up to
> the recipient server receiving the message i.e. the end of the smtp
> transaction. Afterwards I would like to discard the message (send it
> to /dev/null or something), so that the message doesn't place any
> extra strain (cpu cycles, disk i/o) on the system.
> 
> How do I set up an Postfix server so that it accepts mail for any
> domain, any username and then simply deletes the message (sends it to
> /dev/null)?
> 
> 
> Than you,

This should work...

# main.cf
# accept anyuser <at> anydomain
relay_domains = static:ALL
# throw it away
smtpd_end_of_data_restrictions = static:discard
# safety net
default_transport = discard

test before sending it a million messages...

   -- Noel Jones


Gmane