0

I'm having some trouble changing the server I use for Postfix emails.

I've installed postfix on the Linux server (CentOS 5) and setup as follows.

I added the settings to the /etc/postfix/main.cf

relayhost=imap.googlemail.com

smtp_use_tls = yes
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous

Then I created the /etc/postfix/sasl_passwd file with the contents

imap.googlemail.com fake_usernm:fake_passwd

Mapped it in with

postmap /etc/postfix/sasl_passwd

Then everything was working fine but now when I try to change the relayhost to an smtp server mail.example.co.za:26, the email doesn't seem to be sending. I have the checked the maillog which has the following

Sep  7 09:30:23 dev postfix/pickup[32641]: E8BF874E3D4: uid=0 from=<root>
Sep  7 09:30:23 dev postfix/cleanup[32691]: E8BF874E3D4: message-id=<20150907073023.E8BF874E3D4@dev.server.com>
Sep  7 09:30:23 dev postfix/qmgr[32642]: E8BF874E3D4: from=<root@dev.server.com>, size=333, nrcpt=1 (queue active)
Sep  7 09:30:26 dev postfix/smtp[32693]: certificate verification failed for mail.example.co.za: num=20:unable to get local issuer certificate
Sep  7 09:30:26 dev postfix/smtp[32693]: certificate verification failed for mail.example.co.za: num=27:certificate not trusted
Sep  7 09:30:28 dev postfix/smtp[32693]: E8BF874E3D4: to=<trent@example.co.za>, relay=mail.example.co.za[198.57.162.234]:26, delay=4.4, delays=0.07/0.02/3.8/0.51, dsn=5.0.0, status=bounced (host mail.example.co.za[198.57.162.234] said: 550-Verification failed for <root@dev.server.com> 550-The mail server could not deliver mail to root@dev.server.com.  The account or domain may not exist, they may be blacklisted, or missing the proper dns entries. 550 Sender verify failed (in reply to RCPT TO command))
Sep  7 09:30:28 dev postfix/cleanup[32691]: 9D7D374E3D6: message-id=<20150907073028.9D7D374E3D6@dev.server.com>
Sep  7 09:30:28 dev postfix/qmgr[32642]: 9D7D374E3D6: from=<>, size=2642, nrcpt=1 (queue active)
Sep  7 09:30:28 dev postfix/bounce[32695]: E8BF874E3D4: sender non-delivery notification: 9D7D374E3D6
Sep  7 09:30:28 dev postfix/qmgr[32642]: E8BF874E3D4: removed
Sep  7 09:30:28 dev postfix/cleanup[32691]: A72DF74E3D1: message-id=<20150907073028.9D7D374E3D6@dev.server.com>
Sep  7 09:30:28 dev postfix/qmgr[32642]: A72DF74E3D1: from=<>, size=2777, nrcpt=1 (queue active)
Sep  7 09:30:28 dev postfix/local[32696]: 9D7D374E3D6: to=<root@dev.server.com>, relay=local, delay=0.06, delays=0.03/0.01/0/0.02, dsn=2.0.0, status=sent (forwarded as A72DF74E3D1)
Sep  7 09:30:28 dev postfix/qmgr[32642]: 9D7D374E3D6: removed
Sep  7 09:30:31 dev postfix/smtp[32693]: certificate verification failed for mail.example.co.za: num=20:unable to get local issuer certificate
Sep  7 09:30:31 dev postfix/smtp[32693]: certificate verification failed for mail.example.co.za: num=27:certificate not trusted

I don't know what's different and how to go about fixing this

  • The certificate sent by mail.example.co.za is not valid. – sebix Sep 7 '15 at 16:34
0

The errors I was getting seemed to actually be caused by faults in the servers /etc/hosts file.

I was able to reconfigure the hosts file and test

# hostname

output was correct with

dev.server.com

However

# hostname -f

Would output errors but after reconfiguration it would output

dev.server.com

Which is correct and fixed the issues I was having with the relay host

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.