The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,466 other followers

Archive for the ‘postfix’ Category

flush deferred messages in mail queue – SysAdmin Tips

Posted by jpluimers on 2021/03/19

[WayBack] flush deferred messages in mail queue – SysAdmin Tips

In Exim:

# exim -qff

In Postfix:

# postfix flush

In Sendmail:

# sendmail -OTimeout.hoststatus=0m -q -v


Posted in *nix, *nix-tools, exim mail, postfix, Power User, sendmail | Leave a Comment »

Inspecting Postfix’s email queue – Tech-G

Posted by jpluimers on 2021/03/08

[WayBack] Inspecting Postfix’s email queue – Tech-G:



postqueue -p


postcat -vq XXXXXXXXXX

Process (flush) the queue:

postqueue -f


postfix flush

Viewing which senders/receivers are in the queue most:

Try with:
– qshape

More specific:
qshape -s deferred | head ===> deferred mails based on SENDER
qshape deferred | head ===> deferred mails based on RECEIVER

Rate limiting: [WayBack] Postfix Configuration Parameters: default_destination_rate_delay


Posted in *nix, *nix-tools, postfix, Power User | Leave a Comment »

Postfix TLS Support

Posted by jpluimers on 2021/02/25

For my link archive:


Posted in *nix, *nix-tools, Communications Development, Development, Internet protocol suite, postfix, Power User, SMTP | Leave a Comment »

Postfix for relaying SMTP, some info about my own configuration

Posted by jpluimers on 2020/03/20

I’ve a bunch of secondary MX servers using postfix (which I like a lot over sendmail). Basically all their configurations are very similar:

  1. To the file /etc/postfix/relay, add a list of domains to relay for, each ending with a space followed by OK as per
    [WayBack] Configure Postfix to relay mail to multiple internal mail servers w/different domains
  2. Run postmap /etc/postfix/relay to update the relay database file.
  3. Ensure that /etc/postfix/ has these settings (note that the FQDN – in the example – isn’t always returned by hostname --fqdn, see below):
    1. inet_interfaces = all
    2. myhostname =
    3. smtpd_helo_required = yes
    4. smtpd_helo_restrictions = permit_mynetworks, reject_invalid_helo_hostname, reject_non_fqdn_helo_hostname, reject_unknown_helo_hostname
  4. rcpostfix restart && rcpostfix status

Check the functionality with journalctl -u postfix.

FQDN – how to get myhostname

This usually gives a good indication of your external FQDN, but depending on your network circumstances it might not at all be the FQDN of your machine:

dig +noall +answer +short -x `curl -s` | sed 's/\.$//'

I got there through these StackExchange answers:

Testing with sendEmail

Then test with sendEmail from [WayBack] GitHub – mogaal/sendemail: lightweight, command line SMTP email client, with statements like these

The most recent version is now at [Wayback/] GitHub – zehm/sendEmail: SendEmail is a lightweight, command line SMTP email client.

  • sendEmail -o -f -t -u message-subjetc -s -m message-text
  • sendEmail -o -f -t -u message-subjetc -s -m message-text -v -v -v -v

If you get an error containing 450 4.7.1Helo command rejected: Host not found, then reject_unknown_helo_hostname works, but your -o fqdn= parameter contains an invalid hostname.

More sending examples are in the sendEmail documentation.

If you want to know more about fighting SPAM, then continue at [WayBack] Fighting Spam – What can I do as an: Email Administrator, Domain Owner, or User? – Server Fault


Posted in *nix, *nix-tools, postfix, Power User, sendmail | Leave a Comment »

Postfix and blacklists

Posted by jpluimers on 2019/04/19

Still learning postfix configuration, below are some links on how to enable various blacklists that use the RBL DNS (aka [WayBack] DNSBL) way of operations.

They are centered around using the of the [WayBack] Postfix Documentation entry reject_rbl_client listings:

Basically reject_rbl_client is part of smtpd_client_restrictions.


I need to dig further into some other blacklist options than reject_rbl_clientreject_rhsbl_client, reject_rhsbl_reverse_client, reject_rhsbl_sender or reject_rhsbl_recipient restriction.

Then I need to go through these links:

Some blacklist checking links:


Posted in *nix, *nix-tools, postfix, Power User | Leave a Comment »

%d bloggers like this: