4

I was using ubuntu 10.10.

I had a strange situation where I was setting up a small network all with fixed IPs. I had a NAS drive that I had enabled ftp on.

when I used the connect to server menu I was able to connect fine (or just entering in the URL in nautilus).

However from the command line the ftp command didn't work, and gave an unknown host error. I was able to ping the drive however.

In the end I used the gvfs-host command to enable a scripted connection. I'm just wondering if anyone has come across this problem

How to fix this issue ?

  • A little concern have you added the the hostname and IP in the /etc/hosts file ? You can also try telnet x.x.x.x 21 (x.x.x.x = IP of the FTP server) to check that the server is listening on the default FTP port. – Suvasish Sarker Sep 24 '12 at 10:27
  • I was trying to connect just using the IP address so I don't think /etc/hosts should come into play (is that correct?). I would imagine since gvfs-mount was able to connect without any different port parameter that it's just on the usual port 21. – beacon_bonanza Sep 24 '12 at 14:29
  • do you have to provide a username/password in nautilus ? (using ftp with login) or a public ftp – user91632 Sep 26 '12 at 7:50
  • 2012 long time, I'm not sure if it is the case. Try FTP passive mode ftp -p .... Or may be verbose/debug ftp -d -v ... – user.dz Mar 15 '14 at 15:57
1

Please make sure that the configuration file is following these attributes (run sudo nano /etc/vsftpd.conf to edit it):

anonymous_enable=NO
local_enable=YES
write_enable=YES
chroot_local_user=YES

Save and Exit that file

Please make sure the following directory is created and that the permissions are applied to it (replacing user name with the user name of the linux user that will access the system)

mkdir /home/username/files
chown root:root /home/username
sudo service vsftpd restart 

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.