Applicable to:
- Plesk for Linux
- Plesk for Windows
Symptoms
One of the following error messages appears, when connecting to a server via FTP in active mode:
CONFIG_TEXT: Connection timed out
CONFIG_TEXT: Connection refused
CONFIG_TEXT: Connection attempt failed with "ETIMEDOUT - Connection attempt timed out".
Cause
TCP ports 21 and/or 20 is/are filtered.
Resolution
Enable Plesk Firewall to open these ports locally on the server.
Enable Plesk Firewall to open these ports locally on the server.
-
Connect to the Plesk server via SSH.
-
Install the optional package for managing iptables:
-
for CentOS/RHEL-based distributions:
# yum install -y iptables-services
# systemctl enable iptables-services -
for Debian/Ubuntu-based distributions:
# apt install -y iptables-persistent
-
-
Allow incoming connections to the ports 20 and 21:
-
for CentOS/RHEL-based distributions:
# iptables -I INPUT 1 -p tcp --dport=20 -j ACCEPT
# iptables -I INPUT 1 -p tcp --dport=21 -j ACCEPT
# service iptables save -
for Debian/Ubuntu-based distributions:
# iptables -I INPUT 1 -p tcp --dport=20 -j ACCEPT
# iptables -I INPUT 1 -p tcp --dport=21 -j ACCEPT
# iptables-save > /etc/iptables/rules.v4
-
-
Connect to a Plesk server via RDP.
-
Open Windows Firewall in Control Panel.
-
In Windows Firewall, click Advanced settings > Inbound Rules.
-
Make sure the following FTP rules are enabled.
If after opening the FTP ports in a server firewall these ports are still blocked, make sure that:
- A third-party firewall, in case it is used, is not blocking the connection to the FTP ports.
-
An intermediary firewall between a Plesk server and the Internet is not filtering the FTP ports. Contact your Internet Service Provider (ISP) for assistance.
Comments
9 comments
Ftp server working after this steps but after few days I'm in the same situation
Could not read from socket: ETIMEDOUT
Don't know what to do now
I have same problem, and I am not able to connect after following all the steps mentioned in every article. It is holding me up over here. Anyone have the solution?
i do have the same problem am not able to connect via ftp can you please help me to solve the issue
@M. Meijer Could you please clarify the case?
Hello,
Andres Ramos
This means that traffic is still being blocked somewhere. It may be blocked on the server itself, some outside firewall, ISP infrastructure, etc.
Alvaro
Thank you for sharing, this means that traffic is still being blocked at some point.
cant access my files in the first place...
Tex The way I fixed it, was... I'm using AWS Lightsail instances with Plesk... So in the Networking section (AWS Lightsail panel) I had to add a Custom TCP range from 49152 to 65535, also make sure the ports from 20-22 are open. That resolved my problem. FTP works good.
J'ai aussi le même problème impossible de me connecter par le FTP de plesk.
I did all the instructions, open the firewall ports, configured all in the docs, restarted the service and still same error.
Please sign in to leave a comment.