I need to send email notifications to my subscribers, but I can’t do it because of the timeout error.
Please i need to know if it is possible to open port 25 and send emails?

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.

×
1 answer

Hi @redouanadmer,

Firstly, please make sure you a Mail Service which can send mails. If you are uncertain which one, I’ll recommend using Postfix. DigitalOcean have a pretty good tutorial on the installation and configuration of said Postfix. You can view it here - https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-postfix-as-a-send-only-smtp-server-on-ubuntu-16-04

Now onto the port. If you are using ufw, to open port 25 you can use the following command

sudo ufw allow 25/tcp

If you are using Iptables, you can use the bellow

iptables -I INPUT -p tcp -m tcp --dport 25 -j ACCEPT

Regards,
KDSys

by finid
Postfix is a *mail transfer agent* (MTA), an application used to send and receive email. In this tutorial, we will install and configure Postfix so that it can be used to send emails by local applications only — that is, those installed on the same server that Postfix is installed on.
  • It’s not about how to setup Postfix. The OP is facing a problem many of us are facing where DigitalOcean blocks ports like 25, 465 and 587 to be used in Droplets account-wide.

Submit an Answer