Tag Archives: ftp

mount ftp from fstab

install package curlftpfs:
fedora:
dnf install curlftpfs -y
ubuntu:
apt-get install curlftpfs -y

add to /etc/fstab string:

1
curlftpfs#ftpuser:ftppassword@ftp.host.name.com/       /path/to/ftp/mountpoint        fuse    user,ro,noauto,iocharset=utf8,allow_other    0       0

mount /path/to/ftp/mountpoint
ls /path/to/ftp/mountpoint

ProFTPD: without system users

install proftpd
edit /etc/proftpd/proftpd.conf:
RequireValidShell off
AuthOrder mod_auth_file.c
AuthUserFile /etc/proftpd/ftpd.passwd
AuthGroupFile /etc/proftpd/ftpd.group
DefaultRoot ~
wget http://www.castaglia.org/proftpd/contrib/ftpasswd
chmod +x ftpasswd
./ftpasswd --passwd --file=/etc/proftpd/ftpd.passwd --name=john --uid=1 --gid=1 --home=/home/ftp --shell=/bin/false
when creating the next user uid increases by 1.
chmod 777 /home/ftp
/etc/init.d/proftpd restart

vsftpd. FTP for a couple of minutes

 

Merge vsftpd, from here you can ftp://vsftpd.beasts.org/users/cevans/.
sudo -i
mkdir ~/temp | | cd ~/temp
wget ftp://vsftpd.beasts.org/users/cevans/vsftpd-2.3.0pre1.tar.gz
Unpack:
tar xvfz vsftpd-2.3.0pre1.tar.gz
Collect:
make
Appears vsftpd binary, copy it to a folder with the binaries:
cp vsftpd/usr/sbin/
Check whether there is user nobody:
cat /etc/passwd | grep nobody
If not — add:
useradd nobody
For default configuration, you must create a /usr/share/empty/:
mkdir /usr/share/empty/
Next, you need to create ftp user to home directory in /var/ftp/, then it will be the root of our server.
mkdir /var/ftp/
useradd-d /var/ftp ftp
Change the owner of the folders on the root and the appropriate rights:
chown root.root /var/ftp
chmod og-w /var/ftp
Transfer the actual file configuration in /etc:
cp vsftpd.conf /etc
Next edit vsftpd.conf:
vim /etc/vsftpd.conf

Continue reading vsftpd. FTP for a couple of minutes