CentOS7.2 Installation Configuration Vsftpd__centos

Source: Internet
Author: User
Tags anonymous

Install VSFTPD

Yum-y Install VSFTPD

setting up the power-on self-starter

Systemctl Enable Vsftpd.service

Backup Configuration


Edit Configuration

Sed-i "s/anonymous_enable=yes/anonymous_enable=no/g" '/etc/vsftpd/vsftpd.conf '
//disable anonymous user login

sed-i ' s/# Chroot_local_user=yes/chroot_local_user=yes/g "'/etc/vsftpd/vsftpd.conf '
//Prohibit anonymous user login

echo-e" Allow_ Writeable_chroot=yes\npasv_enable=no ">>/etc/vsftpd/vsftpd.conf
//Limit all users to the home directory (yes/no), use active mode only

Create an FTP user

useradd-d/home/wwwroot-g ftp-s/sbin/nologin username *
 * Add user and set home directory to/home/wwwroot and disable login system
 * If you want to modify the home directory to execute the following statement:
 * usermod-d Directory custom username/


chmod-r 777/home/wwwroot
/ /Modify directory Permissions

passwd username
//Enter two times the password you want to set

Restart the VSFTP service

Service VSFTPD Restart

commands that might be used

To review enabled configurations

Start the VSFTP service

Service VSFTPD Start

Stop VSFTP Service

Service VSFTPD Stop

Delete User

Userdel Custom user Name

Delete directory and directory files

RM-RF Directory
* rm-rf/home/wwwroot/* *

deleting files

Rm-f file Path
* * rm-f/home/wwwroot/xxx.log * *

After several hours of tossing, it was OK.
Online tutorials ... Do not know whether they have actually tried, all kinds of errors, can not connect or upload files.
Write down the record here to avoid the same mistakes in the future

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.