Set up DMARC and see who's sending email using your brand's domain.

Is Sendmail configurable through Postmark?

If you use our SMTP server option, you can use a smarthost in Sendmail to relay mail through Postmark. A big advantage of this is that it requires no changes to your application code and the local mail server will queue emails on its own. For instance, in the case there are connection problems to Postmark, the emails will be queued and retried.

Follow the Sendmail configuration steps below to relay SMTP emails through Postmark.

Installing Sendmail

Red Hat Enterprise Linux:

yum install sendmail sendmail-cf


apt-get install sendmail sendmail-cf

Hosts setup

Add your FQDN (fully qualified domain name) to /etc/mail/local-host-names:

hostname -f >> /etc/mail/local-host-names

Ensure that are able to ping your FQDN by performing the following:

ping $(hostname -f)

Authentication setup

Append the following to /etc/mail/, replace API token with your API token. "U:APItoken" "P:APItoken" "M:PLAIN"


echo " "U:APItoken" "P:APItoken" "M:PLAIN"" >> /etc/mail/access

SMTP configuration

Add, or modify, the following lines to /etc/

define('SMART_HOST', '')dnl
define('RELAY_MAILER_ARGS', 'TCP $h 25')dnl
define('ESMTP_MAILER_ARGS', 'TCP $h 25')dnl

Make configurations

Perform the following to create the Sendmail and access configurations.


cd /etc/mail ; m4 > ; makemap hash access <access

Test setup

Restart Sendmail:

/etc/init.d/sendmail restart

The following will send an e-mail from the command line:

echo "testing" > testing.txt ; mail -s "testing" < testing.txt ; rm testing.txt

Generally, any configuration problems will be highlighted in the mail log (/var/log/maillog).

Last updated June 10th, 2020

Still need some help?

Our customer success team has your back!