Linux SCP command and VSFTPD configuration __linux

Source: Internet
Author: User
Tags ftp connection file permissions iptables scp command

Mainly the new server across Haiti to the old server many things need to be copied out, the use of SCP and FTP two ways.1:SCPsudo scp Xxx@192.168.104.32:/file_path/target_path
Address is the server address, File_path is the file to copy from the server, Target_path is the new computer storage path
In turn, you can implement a copy of the new computer to the server file.
2:ftpCompounding method: Google, a lot of. The key is to have the configuration file correct.
How to install is not introduced, here to paste the key configuration.

######### Core Settings ###########

# allow local users to log on
Local_enable=yes

# Write permissions for Local Users
Write_enable=yes

# Local file permissions using FTP, defaults to 077
# generally set to 022
local_umask=022

# When you switch directories
# whether to display the contents of the directory. Message
Dirmessage_enable=yes
Dirlist_enable = NO
#验证方式
#pam_service_name =vsftpd

# Enable data connections for FTP data ports
Connect_from_port_20=yes

# Run with a standalone FTP service
Listen=yes

# Modify Connection Port
#listen_port =2121

######### Anonymous Login Settings ###########

# Allow anonymous Logins
Anonymous_enable=no

# If anonymous logons are allowed
# Whether to turn on anonymous upload permission
#anon_upload_enable =yes

# If anonymous logons are allowed
# Allow anonymous folder creation and upload files within folders
#anon_mkdir_write_enable =yes

# If anonymous logons are allowed
# Anonymous account can have permission to delete
#anon_other_write_enable =yes

# If anonymous logons are allowed
# Anonymous Download rights
# Anonymous for other, can set directory/File attribute control
#anon_world_readable_only =no

# If anonymous logons are allowed
# Limit anonymous user transfer rate, Unit bite
#anon_max_rate =30000

######### User restriction Settings ###########

# # Limit Login

# Use UserList to restrict user access
#userlist_enable =yes

# People on the list don't allow access
#userlist_deny =no

# restricted list file placement path
#userlist_file =/etc/vsftpd/userlist_deny.chroot

# # Limit Directory

# Limit all users to the home directory
#chroot_local_user =yes

# Call to limit the list of users in the home directory
Chroot_list_enable=yes

# The path that restricts the list of users in the home directory
Chroot_list_file=/etc/vsftpd/chroot_list

######### Log Settings ###########

# Log file path settings
Xferlog_file=/var/log/vsftpd.log

# activate the upload/download log
Xferlog_enable=yes

# Use standard log format
#xferlog_std_format =yes

######### Security Settings ###########

# User idle timeout, unit seconds
#idle_session_timeout =600

# Data Connection idle timeout, per second
#data_connection_timeout =120

# Disconnect the client after 1 minutes of idle
#accept_timeout =60

# disconnect 1 minutes before reconnecting
#connect_timeout =60

# Local user transfer rate, Unit bite
#local_max_rate =50000

# Maximum number of connections for FTP
#max_clients =200

# Maximum number of connections per IP
#max_per_ip =5

######### Passive Mode setting ###########

# Open Account Passive mode
Pasv_enable=yes

# Passive Mode minimum port
pasv_min_port=5000

# Passive Mode maximum port
pasv_max_port=6000

######### Other Settings ###########
# Welcome Info
Ftpd_banner=welcome to FTP server!


4 Add FTP Firewall rules:
/sbin/iptables-i input-p TCP--dport 21-j ACCEPT
/etc/rc.d/init.d/iptables Save
/etc/init.d/iptables restart

5 Add Users (note that the Add Nologin type user ftpuser):
useradd-d/home/ftp-s/sbin/nologin Ftpuser
If VSFTPD is started, reboot
Pkill VSFTPD/USR/SBIN/VSFTPD &

then you can FTP connection, the speed is OK.

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.