In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article is about how to configure ftp services in Linux. Xiaobian thinks it is quite practical, so share it with everyone for reference. Let's follow Xiaobian and have a look.
First install the vsftp package for linux.
rpm -qa| gerp vsftpd //find vsftpd installed
If not installed on vsftpd-2.0.1-5.i386.rpm (on the first CD)
The requested URL/media/cdrom was not found on this server.
Here we install without source code. It is installed at rpm.
#rpm -ivh vsftpd-2.0.1-5.i386.rpm
Here it is installed.
service vsftpd start vsftpd service
If nothing is set, the ftp can be accessed anonymously.
note. If you don't have access, please turn off the linux firewall:
iptables -F Clear Firewall
After installing ftp, several files will be generated:
/etc/vsftpd/vsftpd.conf Main configuration file
/etc/vsftpd. ftusers Specifies which users cannot access the FTP server
Whether the user specified in/etc/vsftpd.user_list can access the ftp server is determined by the value of userlist_deny in vsftpd.conf file.
These files are the entire ftp control and forbidden user permissions configuration...
Let's set up a core file for vsftpd
# cd /etc/vsftpd/vsftpd.conf This is the core configuration file for vsftpd
anonymous_enable=YES/no Whether to allow anonymous users to log in
anonymous_enable=yes/no Allow anonymous file uploads
local_enable= YES/no Whether to allow local user login
write_enable= YES/no Whether to allow local user uploads
guest_enable=yes/no Whether to allow virtual user logins;
local_mask=022 Sets the file generation mask for local users to 022, default is 077
dirmessage_enable= YES Set Display.message when switching to directories Implicit file contents
xferlog_enable= YES Enable upload and download logs
connect_from_port_20=YES Enable FTP data port connections
pam_service_name=vsftpd Sets the name of the PAM authentication service configuration file, 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 server access to users in the vsftpd.user_list file
listen= YES/no Whether to use exclusive boot mode (this is important)
tcp_wrappers= YES/no Use tcp_wrappers as host access control
The main thing is these settings. (This is usually the default. Don't move if you don't know too much.)
You can set the following settings:
ftpd_banner=welcome to ftp service Set welcome message after connecting to server
idle_session_timeout=60 How long does it take for a control connection to be disconnected without doing anything after restricting remote client connections (seconds)
data_connection_timeout=120 Sets the idle data interrupt time when the client is transmitting data
accept_timeout=60 Sets how long after a connection is automatically established
connect_timeout=60 Sets the maximum activation time of the data connection, how long it is disconnected, and is used by others;
max_clients=200 indicates that the total number of concurrent client connections to the server is 200
max_per_ip=3 indicates a maximum of 3 connections per client
local_max_rate=50000(50kbytes/sec)
anon_max_rate=30000 Sets the maximum transmission rate limit for local and anonymous users
pasv_min_port= port
pasv-max-prot= port number defines the maximum and minimum port, 0 indicates any port; indicates the port for client connection;
listen_address=IP address Set the address that ftp service listens to, which address the client can use to connect;
listen_port= port number Set the port number of FTP work, default is 21
chroot_local_user=YES Set all local users to chroot
chroot_local_user=NO setting specifies that the user can chroot
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd.chroot_list(only users specified in/etc/vsftpd.chroot_list can execute)
local_root=path Users who can log in regardless of which user, define the home directory of the login account, if not specified, then each user enters the personal user home directory;
chroot_local_user=yes/no Whether to lock the local system account user home directory (all); after locking, the user can only access the user's home directory/home/user, and cannot use the cd command to go up; only down;
chroot_list_enable=yes/no Locks the user's home directory (part) in the specified file, specified in file: /chroot_list_file=path;
userlist_enable=YES/NO Whether to load the user list file;
userlist_deny=YES indicates whether the user loaded above is allowed to deny login;
userlist_file=/etc/vsftpd.user_list List file
These are the advanced settings. You can change it appropriately.
#vi /etc/hosts.allow
vsftpd: 192.168.5.128:DENY Set this IP address not to access ftp service (vsftpd supports tcp_wrappers host access control mode in exclusive startup mode)
Time limit:
#cp /usr/share/doc/vsftpd-1.1.3/vsftpd.xinetd /etc/xinetd.d/vsftpd
#vi /etc/xinetd.d/vsftpd/
modify disable = no
access_time = hour:min-hour:min (add time limit for configuring access (note: corresponds to listen=NO in vsftpd.conf)
For example: access_time = 8:30-11:30 17:30-21:30 indicates that ftp can be accessed only during these two time periods
FTP configuration is basically only these.
Thank you for reading! About "how to configure ftp service in Linux" this article is shared here, I hope the above content can be of some help to everyone, so that everyone can learn more knowledge, if you think the article is good, you can share it to let more people see it!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.