Hello, i want to ask about change port mail server 25. I'm using digitalocean and port 25 on the block, I have to use port 587 or 465. how do I change port 25?

    I also need to change, I use digital ocean, I even opened a ticket, but they said it would only work on port 587

    Hello in order to clarify my problem I can receive emails but I cannot send any :

    May 19 14:54:42 arma3dev postfix/smtp[18536]: connect to eur.olc.protection.outlook.com[104.47.22.161]:587: Connection timed out
    May 19 14:55:12 arma3dev postfix/smtp[18536]: connect to eur.olc.protection.outlook.com[104.47.18.161]:587: Connection timed out
    May 19 14:55:12 arma3dev postfix/smtp[18536]: B02161A00D67: to=<alois.bouny@hotmail.fr>, relay=none, delay=74068, delays=74008/0.02/60/0, dsn=4.4.1, status=deferred (connect to eur.olc.protection.outlook.com[104.47.18.161]:587: Connection timed out)
    May 19 15:09:12 arma3dev postfix/qmgr[26115]: 4FB3E1A00DB7: from=<double-bounce@arma3dev>, size=913, nrcpt=1 (queue active)
    May 19 15:09:15 arma3dev postfix/smtp[19476]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:09:15 arma3dev postfix/smtp[19476]: 4FB3E1A00DB7: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=54948, delays=54945/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:19:12 arma3dev postfix/qmgr[26115]: 271A11A00DC8: from=<double-bounce@arma3dev>, size=886, nrcpt=1 (queue active)
    May 19 15:19:12 arma3dev postfix/qmgr[26115]: 781F71A00DAC: from=<double-bounce@arma3dev>, size=919, nrcpt=1 (queue active)
    May 19 15:19:15 arma3dev postfix/smtp[20101]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:19:15 arma3dev postfix/smtp[20102]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:19:15 arma3dev postfix/smtp[20101]: 271A11A00DC8: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=17260, delays=17257/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:19:15 arma3dev postfix/smtp[20102]: 781F71A00DAC: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=71608, delays=71605/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:24:12 arma3dev postfix/qmgr[26115]: 96A221A00CFF: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:24:12 arma3dev postfix/qmgr[26115]: D9AEB1A00D02: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:24:15 arma3dev postfix/smtp[20417]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:24:15 arma3dev postfix/smtp[20416]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:24:15 arma3dev postfix/smtp[20416]: 96A221A00CFF: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75960, delays=75957/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:24:15 arma3dev postfix/smtp[20417]: D9AEB1A00D02: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75900, delays=75897/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:34:12 arma3dev postfix/qmgr[26115]: A1C291A00D71: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:34:12 arma3dev postfix/qmgr[26115]: 9AA7F1A00D6F: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:34:15 arma3dev postfix/smtp[21046]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:34:15 arma3dev postfix/smtp[21047]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:34:15 arma3dev postfix/smtp[21046]: A1C291A00D71: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75907, delays=75904/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:34:15 arma3dev postfix/smtp[21047]: 9AA7F1A00D6F: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75971, delays=75968/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:39:12 arma3dev postfix/qmgr[26115]: 0C8711A00DB5: from=<contact@arma3dev.fr>, size=842, nrcpt=1 (queue active)
    May 19 15:39:42 arma3dev postfix/smtp[21367]: connect to eur.olc.protection.outlook.com[104.47.14.33]:587: Connection timed out
    May 19 15:40:12 arma3dev postfix/smtp[21367]: connect to eur.olc.protection.outlook.com[104.47.12.33]:587: Connection timed out
    May 19 15:40:12 arma3dev postfix/smtp[21367]: 0C8711A00DB5: to=<alois.bouny@hotmail.fr>, relay=none, delay=63458, delays=63398/0.02/60/0, dsn=4.4.1, status=deferred (connect to eur.olc.protection.outlook.com[104.47.12.33]:587: Connection timed out)
    May 19 15:40:59 arma3dev dovecot: imap-login: Disconnected (no auth attempts in 2 secs): user=<>, rip=104.140.188.30, lip=46.105.213.15, TLS handshaking: SSL_accept() syscall failed: Success, session=<Cj8a+q7CPftojLwe>
    May 19 15:44:12 arma3dev postfix/qmgr[26115]: 917961A00D7E: from=<double-bounce@arma3dev>, size=858, nrcpt=1 (queue active)
    May 19 15:44:15 arma3dev postfix/smtp[21698]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:44:15 arma3dev postfix/smtp[21698]: 917961A00D7E: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75885, delays=75882/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:49:12 arma3dev postfix/qmgr[26115]: 801C11A00D01: from=<contact@arma3dev.fr>, size=577, nrcpt=1 (queue active)
    May 19 15:49:42 arma3dev postfix/smtp[22202]: connect to gmail-smtp-in.l.google.com[108.177.15.27]:587: Connection timed out
    May 19 15:49:42 arma3dev postfix/smtp[22202]: connect to gmail-smtp-in.l.google.com[2a00:1450:400c:c00::1b]:587: Network is unreachable
    May 19 15:49:42 arma3dev postfix/smtp[22202]: connect to alt1.gmail-smtp-in.l.google.com[2a00:1450:4025:c03::1a]:587: Network is unreachable
    May 19 15:50:12 arma3dev postfix/smtp[22202]: connect to alt1.gmail-smtp-in.l.google.com[142.251.9.27]:587: Connection timed out
    May 19 15:50:42 arma3dev postfix/smtp[22202]: connect to alt2.gmail-smtp-in.l.google.com[142.250.150.27]:587: Connection timed out
    May 19 15:50:42 arma3dev postfix/smtp[22202]: 801C11A00D01: to=<bounyalois@gmail.com>, relay=none, delay=77520, delays=77430/0.02/90/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[142.250.150.27]:587: Connection timed out)
    May 19 15:54:12 arma3dev postfix/qmgr[26115]: 038BF1A00D95: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:54:12 arma3dev postfix/qmgr[26115]: E62AA1A00D8A: from=<double-bounce@arma3dev>, size=903, nrcpt=1 (queue active)
    May 19 15:54:15 arma3dev postfix/smtp[22517]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:54:15 arma3dev postfix/smtp[22518]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:54:15 arma3dev postfix/smtp[22517]: 038BF1A00D95: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75930, delays=75927/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:54:15 arma3dev postfix/smtp[22518]: E62AA1A00D8A: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75988, delays=75985/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)
    May 19 15:59:12 arma3dev postfix/qmgr[26115]: 326DD1A00DA4: from=<double-bounce@arma3dev>, size=915, nrcpt=1 (queue active)
    May 19 15:59:15 arma3dev postfix/smtp[22831]: connect to arma3dev[192.168.1.20]:587: No route to host
    May 19 15:59:15 arma3dev postfix/smtp[22831]: 326DD1A00DA4: to=<postmaster@arma3dev>, orig_to=<postmaster>, relay=none, delay=75843, delays=75840/0.02/3.1/0, dsn=4.4.1, status=deferred (connect to arma3dev[192.168.1.20]:587: No route to host)

    I am using alibaba cloud i requested them to open port 25 they refused and asked me to use port 587 or 465 what can i do know?

    aaP_qaisazam70
    when you are not cooking at home what you will do you will go to hotel same way if alibaba is not open port change provider go to another provider

    else use thirdparty email solutions

    rafaelfmachado hello apparently impossible and they do not give any help here when it clearly comes from their panel because me it worked really well and overnight when I did not touch anything or make it no longer worked so you have to fend for yourself on a panel that you did not create.

      RavenRAMIREZ Hello, first open port 25, which is necessary for mail communication. Some servers have 25 ports, which need to be opened to the server for normal use.

      I use a vm on digital ocean, I even opened a ticket there, but they told me the following.

      Thank you for reaching out to us.

      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

      In this case how should I proceed

      7 days later
      12 days later
      18 days later

      no solution yet personal ??

      port 25 has been banned in almost everyone because of spam, all major providers do not accept this port, there is no adjustment that can be done, to work on ports 587 465