Problem VSFTPD VirtualBox

General support questions
Post Reply
dcm2311
Posts: 2
Joined: 2018/02/08 05:14:16

Problem VSFTPD VirtualBox

Post by dcm2311 » 2018/02/08 05:45:53

I created a virtual machine using VirtualBox that runs CentOS Minimal, my main problem is that, I tried to install and configure VSFTPD on it, it run ok locally but when I try to access it from the host (using Filezilla), I get an error that saids:

Estado: Desconectado del servidor
Estado: Resolviendo la dirección de localhost
Estado: Conectando a [::1]:2121...
Estado: Falló intento de conexión con "ECONNREFUSED - Connection refused by server", intentando la siguiente dirección.
Estado: Conectando a 127.0.0.1:2121...
Estado: Conexión establecida, esperando el mensaje de bienvenida...
Estado: Servidor no seguro, no soporta FTP sobre TLS.
Estado: Logged in
Estado: Recuperando el listado del directorio...
Comando: PWD
Respuesta: 257 "/home/xbulldcm"
Comando: TYPE I
Respuesta: 200 Switching to Binary mode.
Comando: PORT 127,0,0,1,198,79
Respuesta: 500 Illegal PORT command.
Comando: PASV
Respuesta: 227 Entering Passive Mode (10,0,2,15,116,179).
Comando: LIST
Error: Connection timed out after 20 seconds of inactivity
Error: Error al recuperar el listado del directorio

I did some port fordwarding and actually I can access to the HTTP service although not to the FTP.

I open the ports on the firewall, tried turning the firewalls off(host and guest), making permissive the Selinux.

I'm new using this SO, so I expected that maybe some one can help me to understand the problem and fix it.

Thanks.

User avatar
TrevorH
Forum Moderator
Posts: 23167
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Problem VSFTPD VirtualBox

Post by TrevorH » 2018/02/08 14:27:01

Using an ftp server via port forwarding is tricky as ftp uses random ports all over the place. It'll be easier if you use bridged networking for your guest and not do the port forwarding part. Use a rule to allow inbound tcp port 21 and then make sure you load nf_conntrack_ftp and it will allow all the other ports for you.
CentOS 5 died in March 2017 - migrate NOW!
Full time Geek, part time moderator. Use the FAQ Luke

dcm2311
Posts: 2
Joined: 2018/02/08 05:14:16

Re: Problem VSFTPD VirtualBox

Post by dcm2311 » 2018/02/08 15:52:41

Thanks, I've already tested it using the Bridge mode and it works, but I'm trying to make it work with the NAT mode :D .

Post Reply