centos vsftpd安装

2023-05-16

1.安装vsftpd

yum install vsftpd 
service vsftpd restart 
vi /etc/vsftpd/vsftpd.conf #配置见最下文
vi /etc/vsftpd/vsftpd.conf chroot_list #配置建最下文
chkconfig vsftpd on

2.添加ftp帐号和目录

useradd -d /home/ftp ftppp 
passwd ftppp

修改指定目录的权限
chown -R ftppp:ftppp  /home/wwwroot

3.端口开启

iptables -I INPUT -p tcp --dport 20 -j ACCEPT
iptables -I INPUT -p tcp --dport 65400:65410 -j ACCEPT

 

# Example 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=NO
#
# Uncomment this to allow local users to log in.
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=60
#
# 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. The vsftpd.conf(5) man page explains
# the behaviour when these options are disabled.
# 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 blah FTP service.
#
# 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
allow_writeable_chroot=YES
#
# 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=NO
#
# 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=YES
#tcp_wrappers=YES
#操作日志记录
dual_log_enable=YES
vsftpd_log_file=/var/log/vsftpd.log
pasv_min_port=65400
pasv_max_port=65410

[root@localhost vsftpd]# cat  chroot_list 

ftpup
ftppp

 

 

 

 

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

centos vsftpd安装 的相关文章

  • 在 CentOS 中使用 /etc/resolv.conf 解析 AD 域

    我已使用 Realm 配置 SSSD 以使用 AD 凭据登录 centOS VM 请参考设置here https stackoverflow com questions 63705156 sssd integration with micr
  • make: *** /lib/modules/2.6.32-279.el6.x86_64/build: 没有这样的文件或目录。停止

    我从他们的网站下载了 RALINK 驱动程序 untar xvf rtl 然后我在其中运行 make 谷歌搜索建议 kernel devel 需要安装 我安装了 kernel devel 软件包 但仍然收到此错误 make lib modu
  • 在Linux中使用自定义规则在多个端口上运行的SSH服务[关闭]

    Closed 这个问题不符合堆栈溢出指南 help closed questions 目前不接受答案 我正在努力设置一台在多个端口上运行 SSH 服务的服务器 例如端口 22 和 5522 这些端口应该具有一组不同的规则 即 我们为端口 2
  • 如何在 CentOs 中安装 php-xml

    我正在尝试在 CentOs 6 5 上安装 php xml 我输入命令yum install php xml 我收到此错误 Loaded plugins fastestmirror Loading mirror speeds from ca
  • 无法在 CentOS 7 上的 PHP 中打开 file_put_contents 上的流

    我知道这是许多线程的常见错误 但我厌倦了搜索 但仍然没有解决它 当我尝试运行该函数时文件放置内容我收到以下错误 Warning file put contents test txt failed to open stream Permiss
  • 在centos中设置Docker_Opts

    我需要设置 docker 在运行 amazon linux centos 的主机上侦听 tcp 0 0 0 0 4243 我看到的所有文档都告诉我运行以下命令 echo DOCKER OPTS H tcp 127 0 0 1 4243 gt
  • 如何找出apache上次重启的时间? [关闭]

    Closed 这个问题是无关 help closed questions 目前不接受答案 我有一个 VPSkloxo控制面板已安装 我在用CentOS 5 8 32 bit 我今天重新启动了 Apache 但忘记了启动时间 知道确切的时间非
  • apache centos 上的多个 php

    如何在 Centos 6 5 上同时运行多个 php 版本 就是这样 要求Centos 6 5 可能适用于 6 6 和 7 Apache Apache 2 2 15 可能与其他版本一起使用 本指南安装和使用FASTCGI 请参阅替代安装的注
  • 在perl中串行处理XML数据

    我想知道在我的情况下 哪种 XML 解析器最适合 Perl 我读了很多书并尝试过XML LibXML and XML SAX 第一个使用了太多内存 第二个对我来说似乎没有那么快 即使在关闭纯 Perl 解析器之后 我的需求相当具体 我通过以
  • crontab 作业的 STDOUT 和 STDERR 输出在哪里

    有谁知道 CentOS 中正常 crontab 作业输出的 STDOUT 和 STDERR 在哪里 我检查了 var log cron文件 但它只记录了 cron 作业执行的时间和命令 没有找到 STDOUT 或 STDERR 内容 看看
  • 无法使用 git 克隆任何存储库

    我尝试克隆一些存储库 但总是遇到相同的错误 我在哪里可以找到有关此错误的更多信息 错误日志文件或类似的文件 或者也许有人知道可能出了什么问题 git clone http github com creationix nvm git nvm
  • 在 systemd 服务文件内/内联添加 shell 命令

    我正在运行gunicorn通过 systemd 将服务器作为服务 这是示例service file Unit Description Gunicorn NGINX After network target Service User root
  • 出现错误 /usr/bin/env: 节点:权限被拒绝

    我已经在我的服务器 Centos 上完成了 ODOO v9 安装 一切都已安装成功 登录页面也可以正常工作 但登录后我收到一个包含以下错误的页面 usr bin env node Permission Denied 我尝试更改权限 但我的问
  • CentOS目录结构是树形的吗?

    CentOS 上有相当于树的东西吗 如果你的 Centos 系统上没有安装 tree 无论如何我通常建议服务器设置使用最小安装磁盘 你应该在命令行中输入以下内容 yum install tree y 如果没有安装 那是因为您没有正确的存储库
  • Monkeyrunner/jython 中未找到 JDBC 驱动程序错误

    我需要在中插入一些东西DB 我在用着JDBC as a connector jython the script mysql数据库和脚本正在运行CentOS 我的代码看起来像这样 from com android monkeyrunner i
  • 如何使用缓存快速重建dockerfile?

    我想优化我的 Dockerfile 我希望将缓存文件保留在磁盘中 但是 当我跑步的时候我发现docker build 它总是尝试从网络获取每个文件 我希望在构建期间共享我的缓存目录 例如 var cache yum x86 64 6 但是
  • 如何使用 nohup 获取正在运行的程序列表

    我正在通过 SSH 连接访问运行 CentOS linux 发行版 的服务器 由于我无法始终保持登录状态 因此我使用 nohup command 来运行我的程序 我找不到如何获取我开始使用 nohup 的所有程序的列表 工作 只有在我注销之
  • php56 - CentOS - Remi 仓库

    我刚刚在测试盒上安装了 php 5 6 正常的 cli php 解释器似乎不存在 gt php v bash php command not found gt php56 v PHP 5 6 13 cli built Sep 3 2015
  • 检查没有 .svn 文件的 svn 存储库

    我的专用服务器 Centos 5 5 上有一个 svn 存储库 位于 var svn myRepository 我只想将这些文件复制到我的生产文件夹 var www myWebapp 中 据我了解 SVN 我只能在本地项目文件夹上使用 sv
  • Centos/Linux 将 logrotate 设置为所有日志的最大文件大小

    我们使用 logrotate 并且它每天运行 现在我们遇到了一些情况 日志显着增长 阅读 gigabaytes 并杀死我们的服务器 所以现在我们想为日志设置最大文件大小 我可以将其添加到 logrotate conf 中吗 size 50M

随机推荐

  • Windows Server 2016 重置密码

    问题描述 xff1a 今天上午的时候 xff0c 系统提示我 xff0c 密码过期 xff0c 需要修改密码 xff0c 我上午就没处理 xff0c 等到下午去处理的时候 xff0c 告诉我 xff0c 在登陆前 xff0c 必须修改用户的
  • 城市列表第三方集成

    城市列表首先要导入两个依赖 xff0c 根据信息放入正确的位置 1 在本app的gradle里面 compile 39 com github andyoom citypicker v1 0 4 39 2 在项目的工作空间build grad
  • Srpingboot+Redis redisTemplate 报空指针异常(注入为NULL)

    今天整合Springboot 43 redis做测试的时候发现了 redisTemplate报空指针错误 原因是注入时候redisTemplate就是null 查了一下后面发现是容器没有启动 单纯的测试是无法注入的 要在测试类上加上 spa
  • KDD 2020 推荐系统论文一览

    作者 学派 链接 https zhuanlan zhihu com p 161705748 编辑 深度传送门 KDD是推荐领域一个顶级的国际会议 本次接收的论文按照推荐系统应用场景可以大致划分为 xff1a CTR预估 TopN推荐 对话式
  • android Button按下及抬起监听事件

    首先我们在 布局中 xff0c 写入Button按钮 lt xml version 61 34 1 0 34 encoding 61 34 utf 8 34 gt lt LinearLayout xmlns android 61 34 ht
  • JZVIdeoPlayer(节操视频播放)

    比如jiecao的视频播放 依赖一个是视频 xff0c picasso 图片加载框架 compile 39 cn jzvd jiaozivideoplayer 6 0 0 39 compile 39 com squareup picasso
  • Android Apk编译的apk安装失败解决

    一 xff1a 如果直接拷贝到手机进行安装 提示安装失败 xff0c 解决有两种 第一 xff1a 在我们项目中的 gradle properties 文件中加入 xff0c 下面的那句 android injected testOnly
  • Android APP第三方支付流程

    手机APP 支付宝接入 1 开发前准备 xff1a 申请一个通过实名认证的企业支付宝账号 下载SDK开发包 提供APP apk以备审核 xff0c 审核通过后即可进行代码集成 2 流程 流程图 xff1a 流程解释 xff1a app携带支
  • Android介绍如何生成keystore 文件并使用

    cmd下 进入到jdk的bin目录 xff0c 这样的话 xff0c android keystore文件就会生成在这个目录下 签名的时候我们需要这个文件 C Program Files Java jdk1 7 0 01 bin gt ke
  • android代码APK混淆

    实际的产品研发中为了防止自己的劳动成果被别人窃取 xff0c 混淆代码能有效防止apk文件被反编译 xff0c 进而查看源代码 说来惭愧 xff0c 作为互联网创业公司的我们也确实对竞品Apk反编译研究过 xff0c 如果Apk混淆之后确实
  • android资源文件混淆

    前面一篇文章我们说过Apk的混淆 xff0c 除了源代码的混淆 xff0c 还有资源文件的混淆 微信推出的apk资源混淆方案 xff0c 该方案的具体原理课参见 xff1a 安装包立减1M 微信Android资源混淆打包工具 微信资源混淆工
  • WebView使用

    https www cnblogs com xunzhi p 6023190 html span class hljs keyword public span span class hljs class span class hljs ke
  • 最新研究:AI已可诊断50种眼疾,1.2秒内确认神经系统疾病

    本文由人工智能观察编译 译者 xff1a Sandy 近年来 xff0c 人工智能技术与医疗健康领域的融合不断加深 xff0c 且在科技巨头与资本巨头积极布局的努力下 xff0c 智能医疗正在不断取得新的突破 而根据 自然医学 xff08
  • stm32 fsmc 功能讲解

    LCD有如下控制线 xff1a CS xff1a Chip Select 片选 xff0c 低电平有效 RS xff1a Register Select 寄存器选择 WR xff1a Write 写信号 xff0c 低电平有效 RD xff
  • go语言基础之面向接口编程示例

    span class token keyword package span main span class token keyword import span span class token punctuation span span c
  • ZynqMP SOC 启动Linux遇到TF卡只读(RO)报错

    如果TF卡作为root启动Linux遇到如下错误 xff1a mmcblk0 mmc0 13ab SE128 115 GiB ro VFS Cannot open root device 34 mmcblk0p2 34 or unknown
  • mmc0: error -84 whilst initialising SD card

    玩zynqMP的板子上的SOC xff0c TF作为root启动petalinux系统 xff0c 碰到如下报错 xff1a error 84 whilst initialising SD card 查询Kernel代码中的sd c也没有看
  • .gradle文件夹下没有gradle.properties

    前言 可直接跳过此段到解决方法 前两天刚配置好Android的环境 xff0c 创建了一个Google的sample 但是在构建的过程中就出了问题 Unable to resolve dependency for 39 app 64 deb
  • eclipse编写web.xml中出现The word '...' is not correctly spelled

    为什么会这样呢 xff1f 因为eclipse中设置了拼写检查 xff0c 解决方法 window gt preferences gt 输入spelling xff0c 将右面的enable spelling checking复选框中的勾去
  • centos vsftpd安装

    1 安装vsftpd yum install vsftpd service vsftpd restart vi etc vsftpd vsftpd conf 配置见最下文 vi etc vsftpd vsftpd conf chroot l