aapanelCentosControl PanelCWPHestia CPLinuxUbuntu

How to check SMTP port 25 is open for email sending out

In this tutorial we’ll check if SMTP port 25 is open for email sending out via Telnet on your Linux machine. Today most of the cloud provider disable the SMTP port 25 to prevent spamming issues. Remember Port 25 is needed to send emails out if it is closed you can’t send email out of the server via any ports despite it is open for you.

Here are the steps to check the SMTP port:

Open the Terminal or ssh on your server.

Type the following command to install telnet if it’s not already installed:

For centos/EL :-

yum install telnet

or for ubuntu/debian :-

apt install telnet

Type the following command and press Enter:

telnet server.uxlinux.com 25

use server.uxlinux.com hostname for better results or replace it with remote server ip or hostname

If the port is open, you will see a message like this:

[root@server]# telnet server.uxlinux.com 25
Connected to server.uxlinux.com.
Escape character is '^]'.
220 server.uxlinux.com

This means that the SMTP port 25 is open and you can send emails.

If the port is closed or you cannot connect to the SMTP server, you will see an error message like this:

Trying server.uxlinux.com...
telnet: connect to address Connection refused
telnet: Unable to connect to remote host

This means that the SMTP port 25 is closed or there is a network restriction and preventing the connection.

If the port is closed, you may need to check your firewall settings or contact your network administrator to troubleshoot the problem.

Sandeep B.

I'm a system admin and php developer and currently working as System Admin In CWP Control panel, expertise in Linux and Windows administration RHEL certified admin.

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button