3

I have virtual box installed on a windows 7 64-bit computer, with Cent OS 5.5 as guest os. I want to be able to use ftp between those. I've installed vsftpd on the guest os, and the guest os uses a nat connection with the host os for internet. So far, I am able to connect to the guest os using ftp (in filezilla), but after the list command is executed, nothing happens, until the command is timed out. This happens in both active and passive mode.

I do have set a pasv_min/max_port in the vsftpd.conf file, listing is enabled, and the ports are redirected in virtualbox. Also the ftp_data_port is set to 20. I also tried setting the pasv_address, but I had to set it to 127.0.0.1, but than filezilla gives me this:

Command:    PASV
Response:   500 OOPS: bad family
Command:    PORT 127,0,0,1,139,204
Response:   500 OOPS: child died

Can someone help me with this?

1 Answer 1

4

Don't use NAT networking mode. Use Bridged and assign the VM a real IP address.

6
  • @brian I also tried that before, but for some reason I can't select a network adapter when I select bridged adapter...
    – Tiddo
    Mar 2, 2011 at 16:14
  • +1. I suspect the reason why NAT networking doesn't work in this case is that VirtualBox's NAT mode doesn't rewrite the FTP PORT or PASV command's IP address and port numbers as they pass through the NAT. Mar 2, 2011 at 16:20
  • @steven so that means I can't use ftp with NAT at all? Is there any other way which doesn't use bridged? Bridged doens't work here...
    – Tiddo
    Mar 2, 2011 at 16:31
  • @Tiddo: My previous statement was mostly speculation. If it is true that VirtualBox's NAT doesn't rewrite the FTP PORT and PASV commands correctly, then FTP won't work with that networking mode. However, bridged networking is not the only other option, as VirtualBox also has "host-only" networking. Mar 2, 2011 at 17:22
  • 1
    Switching to bridged (and configuring static ip address) helped me, thank you very much!
    – NPC
    Apr 5, 2011 at 9:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .