Unable to connect to Filezilla server hosted in Private EC2 windows machine

Need help with FileZilla Server? Something does not work as expected? In this forum you may find an answer.

Moderator: Project members

Post Reply
Message
Author
urek
500 Command not understood
Posts: 5
Joined: 2023-09-18 02:35
First name: Debash
Last name: Bora

Unable to connect to Filezilla server hosted in Private EC2 windows machine

#1 Post by urek » 2023-09-18 03:07

Hi everyone,

I have configured FTP using FileZilla on a private Windows EC2 server, but while trying to connect to it through a different server in same VPC I am getting the below error:
Status: Connecting to x.x.x.x:21...
Status: Connection established, waiting for welcome message...
Status: Initializing TLS...
Status: TLS connection established.
Status: Logged in
Status: Retrieving directory listing...
Status: Server sent passive reply with unroutable address. Using server address instead.
Command: MLSD
Response: 150 About to start data transfer.

These servers access the internet using NAT gateways. I have already allowed incoming ports on the serve security groups and also on the Windows firewall for 20,21 and 45000-451000 for passive mode have also allowed Filezilla server.exe in the exception list.

once it gets connected from the other servers in the VPC I will add an nlb for the public to access this FTP. Any help would be great !!

Thank you

User avatar
botg
Site Admin
Posts: 35566
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#2 Post by botg » 2023-09-18 07:50

You need to tell the server its public IP address. Please study our Network Configuration guide for further information. You can test the server at https://ftptest.net/

urek
500 Command not understood
Posts: 5
Joined: 2023-09-18 02:35
First name: Debash
Last name: Bora

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#3 Post by urek » 2023-09-18 07:56

Hi thanks for responding, since my server is in a private subnet It is not assigned any public IP. but are you referring to the NAT IP through which it is connecting to internet?

User avatar
boco
Contributor
Posts: 26940
Joined: 2006-05-01 03:28
Location: Germany

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#4 Post by boco » 2023-09-18 14:11

It needs the public-facing IP address of the server's network. While not being directly useful for the server, it still needs to know it for telling FTP clients where to connect to for data connections. Without that, the private server address is sent which is useless for the client.
No support requests over PM! You will NOT get any reply!!!
FTP connection problems? Please read Network Configuration.
FileZilla connection test: https://filezilla-project.org/conntest.php
FileZilla Pro support: https://customerforum.fileZilla-project.org

urek
500 Command not understood
Posts: 5
Joined: 2023-09-18 02:35
First name: Debash
Last name: Bora

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#5 Post by urek » 2023-09-19 03:55

I did give it the NAT IP ( the only pubic IP the server will have) but it is still not working.

User avatar
botg
Site Admin
Posts: 35566
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#6 Post by botg » 2023-09-19 07:16

Status: Server sent passive reply with unroutable address. Using server address instead.
Did this message disappear?

urek
500 Command not understood
Posts: 5
Joined: 2023-09-18 02:35
First name: Debash
Last name: Bora

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#7 Post by urek » 2023-09-21 04:02

Yes, but I get below log from client:
Status: Connecting to xx.6.xx7.xx5:21...
Status: Connection established, waiting for welcome message...
Status: Initializing TLS...
Status: TLS connection established.
Status: Logged in
Status: Retrieving directory listing...
Command: PWD
Response: 257 "/" is current directory.
Command: TYPE I
Response: 200 Type set to I
Command: PASV
Response: 227 Entering Passive Mode (xx,1xx,1xx,xx3,xx2,x3)
Command: MLSD
Response: 150 About to start data transfer.
Error: Connection timed out after 20 seconds of inactivity
Error: Failed to retrieve directory listing

urek
500 Command not understood
Posts: 5
Joined: 2023-09-18 02:35
First name: Debash
Last name: Bora

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#8 Post by urek » 2023-09-21 04:43

Thank you for your time, For anyone else who will face a similar issue remember to whitelist the passive port range in the ec2 security group.

Now I will check how can I expose this private instance as FTP server for the public using Network load balancer.

User avatar
botg
Site Admin
Posts: 35566
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: Unable to connect to Filezilla server hosted in Private EC2 windows machine

#9 Post by botg » 2023-09-21 12:22

Status: Connecting to xx.6.xx7.xx5:21...
...
Response: 227 Entering Passive Mode (xx,1xx,1xx,xx3,xx2,x3)
Very untypical to see different IPs used for control and data connection. Unless the FTP server software itself performs load-balancing with multiple backends, this very likely means that the server has not been told the correct public IP address.

Post Reply