Uncategorized

Digital Ocean’s VPS servers cannot be used to open the SMTP port 25 for sending emails.

I previously purchased a DigitalOcean server and used it for a few days. It performed well in terms of speed and overall performance.

In the past two days, I set up a Baota mail server on DigitalOcean. I can receive emails normally, but I cannot send them. Currently, most VPS providers have closed the SMTP port, making it impossible to send emails.

I tried opening port 25 in AApanel and also attempted to open it in the DigitalOcean control panel, but I was unable to receive emails.

So, I submitted a ticket to customer support. You can find their contact information in the same place where you would create a support ticket. It seems that online chat support is not popular nowadays, and tickets are the preferred method of communication.

digital ocean contact support

I requested them to open port 25 for me:

Hi, can you Please help me open port 25 service Thank you

The response I received was that they couldn’t open the SMTP port due to concerns about users sending spam emails, as shown in the screenshot:

Of course, the customer support also provided a solution. If you are interested, you can take a look at the original response.

As for why they don’t open the SMTP port, you can read their explanation:

Hello there,

Thank you for contacting DigitalOcean.

Our apologies for any inconvenience caused here. Stopping spam is a constant fight and due to this, your account has restrictions specifically on port 25.

However, you are able to use mail services using ports 587, 993, 995 and 465. You will need to open these ports in your firewall. Here is our guide to common iptables commands:

https://www.digitalocean.com/community/tutorials/iptables-essentials-common-firewall-rules-and-commands#service-mail

We realize this is inconvenient for sending mail from your Droplet. As a solution, you can consider using a third party service such as SendGrid or similar to processes mail there instead of your Droplet. We apologize for the frustration but we’re not able to lift this port restriction at this time.

In terms of a workaround, here are a few alternatives:

1. Utilize port 587 for SMTP relay via another mail provider, for example, G Suite/Gmail, Mailgun, etc. We have a guide on doing so using Postfix here:

https://www.digitalocean.com/community/tutorials/how-to-set-up-a-mail-relay-with-postfix-and-mailgun-on-ubuntu-16-04

2. Configure your app or service to send mail directly using either an SMTP client connection (typically using port 587), or API call via another mail provider such as Sendgrid, Mailgun, Mandrill, etc.

Please note that with this restriction in place on port 25, mail servers hosted here will be unable to directly relay email to other mail servers, as communication between mail servers typically takes place on port 25.

We think the API is the best solution, as it is honestly more scalable and what we would use if we wanted to “future proof” the project.

Please let us know in case of any further questions. We’re always here to help.

Regards,

Nazim Abbas
Developer Experience Specialist
DigitalOcean

 

In simple terms, they are concerned about users using their VPS for mass sending of spam emails, which is understandable.

 

You can check if port 25 is open on your VPS by running the following command in SSH:

 

netstat -anltup | grep :25

 

Although you cannot set up a mail server on the VPS to send emails, you can still use various third-party websites to set up an enterprise mail server for sending emails, such as ZOHO, and others.

 

 

Related posts

Exploring the Eco-Friendly Power of Green Geeks Hosting

admin

FastComet Hosting: Unleashing the Power of Seamless Web Hosting

admin

Enhancing Customer-Facing Team Efficiency: A Comprehensive Sapling.ai Review

admin

The Ultimate Choice for Small Business: GreenGeeks – The Best Web Hosting for Small Business

admin

Navigating the Web Hosting Cloud: My Experience with DigitalOcean

admin

FastComet: Elevating Your Website Hosting Services Experience

admin