The instructions below help you configure Plesk to send mail to our systems. You must have basic command line knowledge to execute the commands referenced. Make sure to backup any Postfix files referenced here that already exist before you make any changes to them!
Step 1: Create a password file
Under the '/etc/postfix' folder create a file called 'password':
# vi /etc/postfix/password
The file should have the following contents:
(REPLACE username:password with your Sendmetric smtp username and password you create in our control panel)
smtp.sendmetric.com username:password
Step 2: Change Permissions on password file & Create Lookup Table
Execute the following commands:
# chown root:root /etc/postfix/password
# chmod 0600 /etc/postfix/password
# postmap hash:/etc/postfix/password
Step 3: Add X-AuthUser Header
In order for our systems to know who the actual authenticated sender of the message was please create a file called: '/etc/postfix/header_custom' with the following:
# vi /etc/postfix/header_custom
/^Received: (.*Authenticated sender:)([^)]*)(.*)/i PREPEND X-AuthUser: $2
Step 4: Postfix Smarthost Authentication
Open the main postfix configuration file and append the content below at the end of the file.
DO NOT FORGET TO BACKUP THE FILE PRIOR TO EDITING IT.
# vi /etc/postfix/main.cf
relayhost = smtp.sendmetric.com smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/password smtp_sasl_security_options = noanonymous smtpd_sasl_authenticated_header = yes smtp_tls_security_level = encrypt smtp_header_checks = regexp:/etc/postfix/header_custom
Step 5: Restart the Postfix Service
You must restart postfix for the changes to take effect, prior to restarting make sure to check your configuration by running the following command to verify no errors:
# postfix check
After running the above command and verifying nothing is wrong issue the restart command below:
# /etc/init.d/postfix restart