Article Title: linuxftp virtual server. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
The following is the basic configuration of ftp in linux in a Virtual Machine (redhat AS 4.0 is used AS an example ):
First, install the vsftp package in linux.
Rpm-qa | gerp vsftpd // find whether vsftpd is installed
Vsftpd-2.0.1-5.i386.rpm if not installed (on the first disc)
In linux, an important point is to mount the optical drive mount/media/cdrom.
Here we do not need to install the source code. Use rpm for Installation
# Rpm-ivh vsftpd-2.0.1-5.i386.rpm
The installation is completed here.
Service vsftpd start vsftpd service
If no ftp address is set, the ftp address can be accessed anonymously.
Note: if you cannot access the firewall, disable the firewall for linux:
Iptables-F clear firewall
After ftp is installed, several files will be generated:
/Etc/vsftpd. conf main configuration file
/Etc/vsftpd. ftpusers specifies which users cannot access the FTP server
Whether the user specified in the/etc/vsftpd. user_list file can access the ftp server is determined by the value of userlist_deny In the vsftpd. conf file.
These files are used to control the entire ftp and prohibit the user's permission configuration...
Next we will set up a core vsftpd file.
# Cd/etc/vsftpd. conf this is the core configuration file of vsftpd.
Anonymous_enable = YES/no whether anonymous users are allowed to log on
Anonymous_enable = yes/no whether file upload is allowed anonymously
Local_enable = YES/no whether local users are allowed to log on
Write_enable = YES/no whether local user upload is allowed
Guest_enable = yes/no whether virtual user login is allowed;
Local_mask = 022 set the local user's file generation mask to 022, default value: 077
Dirmessage_enable = YES: displays the content of the. message implicit file when switched to the directory.
Xferlog_enable = YES activate upload and download logs
Connect_from_port_20 = YES Enable FTP data port connection
Pam_service_name = vsftpd: Set the name of the configuration file for the PAM Authentication Service, which is stored in the/etc/pam. d directory.
Userlist_enable = YES allow users in the vsftpd. user_list file to access the server
Userlist_deny = YES deny access to the server from users in the vsftpd. user_list File
Listen = YES/no whether exclusive startup mode is used (this is important)
Tcp_wrappers = YES/no whether tcp_wrappers is used as the host Access Control Method
These settings are the most important. (This is generally the default one, not too understandable)