1

I was able to install de FTP server (vsFTPd) with a user and password. Configured the security group:

enter image description here

I can connect internally from the machine with "ftp localhost", but trying with filezilla from another machine I get Connection timed out. The configuration is like this:

pasv_addr_resolve=NO
pasv_address=X.X.X.X
pasv_enable=YES
pasv_min_port=1024
pasv_max_port=1048
port_enable=YES

X.X.X.X is the public IP of the EC2 machine

Edit Adding IPTABLES info:

$ sudo iptables -S
-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-A INPUT -p tcp -m tcp --dport 21 -j ACCEPT
-A INPUT -p tcp -m tcp --sport 20 --dport 1024:1048 -j ACCEPT
-A INPUT -p tcp -m state --state NEW -m tcp --dport 20:21 -j ACCEPT
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
-A INPUT -p tcp -m tcp --dport 21 -j ACCEPT
  • did you allow it in iptables? also I would definitely recommend using the sftp server built into openssh. It is way more secure and easier to work with imo. – Desultory Jan 3 '18 at 21:12
  • I guess so. Edited my original post to add that information. – Mariano L Jan 3 '18 at 21:19
  • And I'm using FTP because is a third party app that only have this option. I need FTP access. – Mariano L Jan 3 '18 at 21:22
  • try setting the ip in the conf to 0.0.0.0, oh and you can try connecting to it with telnet to see if it is a network error or an error with vsftpd – Desultory Jan 3 '18 at 21:47
  • 1
    Does the instance have a public IP address (might be trivial, but definately worth checking).\ – ryekayo Jan 3 '18 at 22:06
0

Check:

  • the instance has public IP
  • the subnet has internet gateway attached to default route
  • the NACLs for the subnet allows your FTP ports

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.