1.确认是否已安装 ftp

1
pgrep vsftpd   #查看ftp 服务进程

无结果如下图所示

2.执行安装

1
yum install vsftpd     #安装ftp 服务

3.执行过程确认即可(输入y)

4.查看ftp 是否安装成功

1
systemctl status vsftpd.service  #查看服务状态

5.查看配置文件

1
cd   /etc/vsftpd/vsftpd.conf 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
# mple config file /etc/vsftpd/vsftpd.conf
#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
# Allow anonymous FTP? (Beware - allowed by default if you comment this out).
#anonymous_enable=YES
anonymous_enable=NO
 
#
# Uncomment this to allow local users to log in.
# When SELinux is enforcing check for SE bool ftp_home_dir
local_enable=YES
#
# Uncomment this to enable any form of FTP write command.
write_enable=YES
#
# Default umask for local users is 077. You may wish to change this to 022,
if your users expect that (022 is used by most other ftpd's)
local_umask=022
#
# Uncomment this to allow the anonymous FTP user to upload files. This only
# has an effect if the above global write enable is activated. Also, you will
# obviously need to create a directory writable by the FTP user.
# When SELinux is enforcing check for SE bool allow_ftpd_anon_write, allow_ftpd_full_access
#anon_upload_enable=YES
#
# Uncomment this if you want the anonymous FTP user to be able to create
new directories.
#anon_mkdir_write_enable=YES
#
# Activate directory messages - messages given to remote users when they
# go into a certain directory.
dirmessage_enable=YES
#
# Activate logging of uploads/downloads.
xferlog_enable=YES
#
# Make sure PORT transfer connections originate from port 20 (ftp-data).
connect_from_port_20=YES
#
# If you want, you can arrange for uploaded anonymous files to be owned by
# a different user. Note! Using "root" for uploaded files is not
# recommended!
#chown_uploads=YES
#chown_username=whoever
#
# You may override where the log file goes if you like. The default is shown
# below.
#xferlog_file=/var/log/xferlog
#
# If you want, you can have your log file in standard ftpd xferlog format.
# Note that the default log file location is /var/log/xferlog in this case.
xferlog_std_format=YES
#
# You may change the default value for timing out an idle session.
#idle_session_timeout=600
#
# You may change the default value for timing out a data connection.
#data_connection_timeout=120
#
# It is recommended that you define on your system a unique user which the
# ftp server can use as a totally isolated and unprivileged user.
#nopriv_user=ftpsecure
#
# Enable this and the server will recognise asynchronous ABOR requests. Not
# recommended for security (the code is non-trivial). Not enabling it,
# however, may confuse older FTP clients.
#async_abor_enable=YES
#
# By default the server will pretend to allow ASCII mode but in fact ignore
# the request. Turn on the below options to have the server actually do ASCII
# mangling on files when in ASCII mode.
# Beware that on some FTP servers, ASCII support allows a denial of service
# attack (DoS) via the command "SIZE /big/file" in ASCII mode. vsftpd
# predicted this attack and has always been safe, reporting the size of the
# raw file.
# ASCII mangling is a horrible feature of the protocol.
#ascii_upload_enable=YES
#ascii_download_enable=YES
#
# You may fully customise the login banner string:
#ftpd_banner=Welcome to FTP service.
ftpd_banner=server.
#
# You may specify a file of disallowed anonymous e-mail addresses. Apparently
# useful for combatting certain DoS attacks.
#deny_email_enable=YES
# (default follows)
#banned_email_file=/etc/vsftpd/banned_emails
#
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
# (Warning! chroot'ing can be very dangerous. If using chroot, make sure that
# the user does not have write access to the top level directory within the
chroot)
#chroot_local_user=YES
#chroot_list_enable=YES
# (default follows)
#chroot_list_file=/etc/vsftpd/chroot_list
#
# You may activate the "-R" option to the builtin ls. This is disabled by
default to avoid remote users being able to cause excessive I/O on large
# sites. However, some broken FTP clients such as "ncftp" and "mirror" assume
# the presence of the "-R" option, so there is a strong case for enabling it.
#ls_recurse_enable=YES
#
# When "listen" directive is enabled, vsftpd runs in standalone mode and
# listens on IPv4 sockets. This directive cannot be used in conjunction
# with the listen_ipv6 directive.
listen=YES
#
# This directive enables listening on IPv6 sockets. By default, listening
# on the IPv6 "any" address (::) will accept connections from both IPv6
and IPv4 clients. It is not necessary to listen on *both* IPv4 and IPv6
# sockets. If you want that (perhaps because you want to listen on specific
# addresses) then you must run two copies of vsftpd with two configuration
# files.
# Make sure, that one of the listen options is commented !!
#listen_ipv6=YES
 
pam_service_name=vsftpd
userlist_enable=NO
local_root=/var/www/html
tcp_wrappers=YES
dual_log_enable=YES
use_localtime=YES

上面配置文件是可用配置,相关选项请百度作用

6.关闭防火墙并禁止开机启动

1
2
systemctl stop firewalld.service
systemctl disable firewalld.service

7.设置selinux

1
2
3
4
vi /etc/selinux/config
  #SELINUX=enforcing #注释掉
  #SELINUXTYPE=targeted #注释掉
  SELINUX=disabled #增加

8.关闭selinux

1
setenforce 0

9.添加帐号

1
2
useradd 用户名
passwd  用户名  密码

linux 下安装ftp 并远程连接的更多相关文章

  1. Linux下安装MySQL及远程连接MySQL

    安装方式一:通过下载官方安装包安装 由于Linux安装MySQL会遇到各种依赖问题,本博文整理了下安装方放,避免遇到依赖问题 查看是否自带mariadbrpm -qa|grep mariadb然后卸载 ...

  2. linux 下安装ftp服务器

    最后重启    # service vsftpd restart   1.查看是否安装vsftp rpm -qa | grep ftp 如果出现    vsftpd-2.0.5-16.el5_5.1 ...

  3. 操作笔记:linux下安装ftp

    1,安装ftp [root@iZ945sgm0ugZ ~]# yum install vsftpd 安装成功的信息: [root@iZ945sgm0ugZ ~]# yum install vsftpd ...

  4. Linux下设置mysql允许远程连接

    最近在Linux上安装了Mysql,然后在Windows环境下通过Navicat来连接时,出现报错:1045 Access denied for user 'root'@'XXX' (using pa ...

  5. linux下安装FTP详细

    一:安装ftp 1.检查是否安装了 ftp :(下图是已安装的效果,没安装没有展示) rpm -qa|grep vsftpd 2.安装指令:(找一个  -y  指令) yum install -y v ...

  6. Linux下安装FTP

    1.查询进程是否有ftp服务 ps -ef|grep vsftpd 查询是否安装vsftpd: rpm -qa |grep vsftpd (rpm的安装:apt-get install rpm) 2. ...

  7. Linux下开启MySQL的远程连接

    今天在用客户端工具远程连接mysql的时候,连接不上,以为是防火墙,关了防火墙后依然打不开,后开在网上查了下原来mysql基于安全考虑root账户一般只能本地访问,但是在开发过程中可能需要打开root ...

  8. Ubuntu 16.04下安装MySQL及远程连接

    最近因为要研究一个关于MySQL的漏洞,所以需要MySQL的环境,就用了近一个小时的时间搭建了一个,期间出了点问题,故记录于此. 1.首先是安装,在命令窗口中输入下面三条命令即可. sudo apt- ...

  9. Linux下安装FTP服务(Ubuntu)

    在Ubuntu 14.04 上安装 FTP 服务 第一步>>更新库 linuxidc@linuxidc:~$ sudo apt-get update 第二步>>采用如下命令安装 ...

随机推荐

  1. mysql 提示表损坏处理方法

     公司网站有些页面打不开,第二次出现这个情况 重启数据库,提示有一个表crashed:这是第二次出现这个问题,这个时候,进入数据库文件目录输入:myisamchk -r "Table_Nam ...

  2. BZOJ 4833: [Lydsy1704月赛]最小公倍佩尔数(数论 + 最值反演)

    题面 令 \({(1+\sqrt 2)}^n=e(n)+f(n)*\sqrt2\) ,其中 \(e(n),f(n)\) 都是整数,显然有 \({(1-\sqrt 2)}^n=e(n)-f(n)*\sq ...

  3. 【BZOJ1831】[AHOI2008]逆序对(动态规划)

    [BZOJ1831][AHOI2008]逆序对(动态规划) 题面 BZOJ 洛谷 题解 显然填入的数拎出来是不降的. 那么就可以直接大力\(dp\). 设\(f[i][j]\)表示当前填到了\(i\) ...

  4. Nifi flow 备份恢复

      1. 备份  copy 下面的文件到本地: conf/flow.xml.gz   2. 恢复 新安装一个nifi的环境,把这个文件copy到conf文件夹下 运行nifi, 在界面上create ...

  5. VLAN报文和非VLAN以太网报文的区别

    VLAN(Virtual Local Area Network,虚拟局域网)协议,基于802.1Q协议标准. 以太网带VLAN帧结构,是在以太网报文中,位于数据帧中“发送源MAC地址”与“类别/长度域 ...

  6. IT项目管理——《人月神话》读后感

    这也许是和候红老师的最后的几节课了吧,侯老师是一个很有思想深度,很关心同学的好老师. 一开学就布置了阅读<人月神话>的作业,说实话,我没有看,以我的速度可能2.3个小时就看完了,但是我觉得 ...

  7. centos7安装较高版本python3.5/3.6

    应用环境: Centos7或者RHEL7下默认安装的python版本为2.7.x,更新不够及时,现在很多时候需要额外安装较高版本的python环境, 网上搜罗一圈总结记录一下常用两种方式: ① 源码编 ...

  8. centos7破解安装confluence5.9.11

    应用环境:Confluence是一个专业的企业知识管理与协同软件,也可以用于构建企业wiki.通过它可以实现团队成员之间的协作和知识共享. 安装环境:centos7.3 Java环境 1.7.0_79 ...

  9. [THUWC2017]在美妙的数学王国中畅游

    [THUWC2017]在美妙的数学王国中畅游 e和sin信息不能直接合并 泰勒展开,大于21次太小,认为是0,保留前21次多项式即可 然后就把e,sin ,kx+b都变成多项式了,pushup合并 上 ...

  10. RedHat下安装MySQL5.5

    MYSQL在windows下面安装可能一帆风顺,但是如果真的到纯图形界面的redhat服务器上,可能就不是那么容易了, 这里我就详细的介绍一下MYSQL5.5在linux下的安装以及注意的问题,避免后 ...