Id like to configure my server the ability to send thru SMTP (not recieve) emails thru my external SMTP server on CentOS for wordpress and general logging.
How can I do this?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!
Hello there,
It is recommended to use ports 465 or 587 instead of insecure ports like 25 and also to use an SMTP plugin as well.
That way you will be able to specify an SMTP server with authentication which your emails would be going through. You could for example use Gmail’s SMTP settings. This would drastically increase the delivery rate of your emails as well compared to using plain PHP mail.
I’ve been using this plugin for a while now and it works very well: Easy WP SMTP
I’ll also recommend using a third-party mail provider like SendGrid to send your emails. You can also check this tutorial on: Why You May Not Want To Run Your Own Mail Server
https://www.digitalocean.com/community/tutorials/why-you-may-not-want-to-run-your-own-mail-server
Hope that this helps!
Hi @riahc4
May I recommend that you don’t use Sendmail, but use something like Postfix, which has a much better security track record? It’s a drop-in-replacement for Sendmail.
I’m not sure if CentOS comes with the wizard, like Ubuntu does, but run the installation:
Then have a look at the Ubuntu tutorial, but ignore the two first
sudo apt ...
commands and skip Step 3: https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-postfix-as-a-send-only-smtp-server-on-ubuntu-16-04