cd vsFTPd-2.3.5-ext.1
sudo apt-get install make gcc libwrap0-dev libcap-dev libpam-dev libssl-dev
make
sudo make install
sudo cp vsftpd.8 /usr/share/man/man8/
sudo cp vsftpd.conf.5 /usr/share/man/man5/
sudo mkdir -p /srv/ftp
sudo addgroup --system ftp
sudo adduser --system --home /srv/ftp --no-create-home --ingroup ftp --disabled-password --disabled-login ftp
sudo /etc/init/vsftpd.conf
# vsftpd - FTP Daemon # description "vsftpd daemon" author "Chuck Short" start on (filesystem and net-device-up IFACE!=lo) stop on runlevel [!2345] respawn pre-start script check_standalone_mode() { # Return 1 if vsftpd.conf doesn't have listen yes or listen_ipv6=yes CONFFILE="/etc/vsftpd/vsftpd.conf" if [ -e "${CONFFILE}" ] && ! egrep -iq "^ *listen(_ipv6)? *= *yes" "${CONFFILE}" then echo "${CONFFILE}: listen disabled - service will not start" return 1 fi } [ -d /usr/share/empty ] || install -m 755 -o root -g root -d /usr/share/empty check_standalone_mode || stop end script exec /usr/local/sbin/vsftpd
sudo ln -s /lib/init/upstart-job /etc/init.d/vsftpd
sudo nano /etc/vsftpd/vsftpd.conf
anonymous_enable=NO local_enable=YES write_enable=YES local_umask=022 chroot_local_user=YES pam_service_name=vsftpd pasv_min_port=49152 pasv_max_port=65535 hide_ids=YES allow_writable_root=YES local_max_rate=1000000 # Maximum data transfer rate in bytes per second max_clients=50 # Maximum number of clients that may be connected max_per_ip=4 # Maximum connections per IP
Tidak ada komentar:
Posting Komentar