Page 1 of 1

SMTP outgoing random ports

Posted: Mon Feb 16, 2015 2:36 am
by philly75
Hi All,

Can anyone please advise why my server gets random ports for outgoing mail?
Running this: netstat -plan| grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 23511/exim
tcp 0 0 0.0.0.0:2525 0.0.0.0:* LISTEN 23511/exim
tcp 0 1 192.168.1.110:48673 65.55.92.136:25 SYN_SENT 21525/exim
tcp 0 1 192.168.1.110:48671 65.55.92.136:25 SYN_SENT 24051/exim
tcp 0 1 192.168.1.110:48672 65.55.92.136:25 SYN_SENT 23016/exim
tcp 0 1 192.168.1.110:36137 65.54.188.94:25 SYN_SENT 24308/exim
tcp 0 0 :::25 :::* LISTEN 23511/exim
tcp 0 0 :::2525 :::* LISTEN 23511/exim


192.168.1.110 is my servers internal IP and I have submitted a form off my web page, and this is what i see displayed as connections on port 25, see the server IP attached to random ports?

I have installed vestacp, all the default ports for smtp are active, 25,465,587,2525

I have opened my firewall for these SMTP ports to ALLOW to the server but does not.

POP works but SMTP does not.I have removed sendmail and postfix, so only exim and devcot is running.

Anyone have any ideas?

Thanks
Phil

Re: SMTP outgoing random ports

Posted: Mon Feb 16, 2015 5:14 pm
by sanna
philly75 ,
with
netstat -plan| grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LIST EN 28935/exim
tcp 0 0 0.0.0.0:2525 0.0.0.0:* LIST EN 28935/exim
tcp 0 0 :::25 :::* LIST EN 28935/exim
tcp 0 0 :::2525 :::* LIST EN 28935/exim

I have this :
Why support ? See this viewtopic.php?f=12&t=6180

many thanks

Re: SMTP outgoing random ports

Posted: Mon Feb 16, 2015 10:15 pm
by philly75
Hi,

Send an email somewhere or attempt to send one and then run that same command.

Thanks

Re: SMTP outgoing random ports

Posted: Tue Feb 17, 2015 7:44 pm
by skurudo
/etc/exim4/exim4.conf.template

Code: Select all

daemon_smtp_ports = 25 : 465 : 587 : 2525

Re: SMTP outgoing random ports

Posted: Wed Feb 18, 2015 10:50 pm
by sanna
skurudo wrote:/etc/exim4/exim4.conf.template

Code: Select all

daemon_smtp_ports = 25 : 465 : 587 : 2525
Yes I have this in exim.conf (not exim4)

daemon_smtp_ports = 25 : 465 : 587 : 2525

I dont have exim.conf.template file:
/etc/exim/exim.conf.template
-bash: /etc/exim/exim.conf.template: No such file or directory

Re: SMTP outgoing random ports

Posted: Thu Feb 19, 2015 12:26 am
by philly75
Same here.

It seems that VestaCP is doing this or perhaps NGINX reverse proxying something.

There is no way that anyone else in this forum has not come across this and fixed it. If not then no on is using a firewall policy based and has all ports open to public.

I am behind a firewall and I have a BLOCK all rule to my server and have opened ports 80, 443, and all SMTP ports:
25 : 465 : 587 : 2525 and I have opened POP3 before smtp on firewall.

Exim though chooses random ports to send out. Who can help and how to fix this?

Re: SMTP outgoing random ports

Posted: Thu Feb 19, 2015 3:50 pm
by sanna
philly75 wrote:Hi,

Send an email somewhere or attempt to send one and then run that same command.

Thanks
the same,I am waiting for a script installation's email but nothing

[root@srv1 ~]# netstat -plan| grep :25
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 2808/exim
tcp 0 0 0.0.0.0:2525 0.0.0.0:* LISTEN 2808/exim
tcp 0 0 :::25 :::* LISTEN 2808/exim
tcp 0 0 :::2525 :::* LISTEN 2808/exim
[root@srv1 ~]#