Ubuntu
-
Install ftp server: sudo apt-get install vsftpd;
-
Configuration: modify /etc/vsftpd.conf:
i. Enable upload: uncomment "write_enable=YES"
i. Restrict user in their home directory: uncomment following lines:
chroot_local_user=YES chroot_list_enable=YES chroot_list_files=/etc/vsftpd.chroot_list
then create a /etc/vsftpd.chroot_list containing a list of users one per line.
-
Restart vsftpd: sudo /etc/init.d/vsftpd restart
Ref:
https://help.ubuntu.com/10.04/serverguide/ftp-server.html http://serverfault.com/questions/354671/ubuntu-vsftpd-server-error-500-oops-could-not-read-chroot-list-file-etc-vsf
CentOS
See note "Install FTP Service for CentOS 6.3 Host behind a Proxy".