`
baobeituping
  • 浏览: 1068083 次
  • 性别: Icon_minigender_1
  • 来自: 长沙
社区版块
存档分类
最新评论

Linux安装FTP

阅读更多

1、配置及要求


操作系统:Debian/Linux

一块网卡:eth0

eth0:192.168.61.199  

2、安装vsftpd


sh# apt-get install vsftpd 

vsftpd.conf配置如下:

# Example config file /etc/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.
#
#
# Run standalone?  vsftpd can run either from an inetd or as a standalone
# daemon started from an initscript.
listen=YES
#
# Run standalone with IPv6?
# Like the listen parameter, except vsftpd will listen on an IPv6 socket
# instead of an IPv4 one. This parameter and the listen parameter are mutually
# exclusive.
#listen_ipv6=YES
#
# Allow anonymous FTP? (Beware - allowed by default if you comment this out).
#anonymous_enable=YES
#
# 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.
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

local_root=/home/localuser
anon_root=/home/anonuser
#
# 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/vsftpd.log
#
# If you want, you can have your log file in standard ftpd xferlog format
#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 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 restrict local users to their home directories.  See the FAQ for
# the possible risks in this before using chroot_local_user or
# chroot_list_enable below.
#chroot_local_user=YES
#
# 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().
#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
#
#
# Debian customization
#
# Some of vsftpd's settings don't fit the Debian filesystem layout by
# default.  These settings are more Debian-friendly.
#
# This option should be the name of a directory which is empty.  Also, the
# directory should not be writable by the ftp user. This directory is used
# as a secure chroot() jail at times vsftpd does not require filesystem
# access.
secure_chroot_dir=/var/run/vsftpd
#
# This string is the name of the PAM service vsftpd will use.
pam_service_name=vsftpd
#
# This option specifies the location of the RSA certificate to use for SSL
# encrypted connections.
rsa_cert_file=/etc/ssl/certs/vsftpd.pem



ftpusers 配置如下

# /etc/ftpusers: list of users disallowed FTP access. See ftpusers(5).

#root
#bossuser
#test
#test02
daemon
bin
sys
sync
games
man
lp
mail
news
uucp
nobody

重启vsftpd

/etc/init.d/vsftpd restart

参考文献:http://vincent-feng.iteye.com/admin/blogs/295210

分享到:
评论

相关推荐

    Linux离线安装ftp安装包

    离线安装FTP服务器需要对Linux系统有一定了解,但只要按照上述步骤操作,即使在没有网络连接的情况下,也能顺利安装和配置`vsftpd`。这个过程不仅有助于学习Linux系统的管理,也为在特殊环境下部署FTP服务提供了实用...

    Linux下安装FTP

    在Linux系统中安装FTP服务,这里以Apache FtpServer为例,整个过程包括FTP服务器软件的下载、解压、依赖环境的安装(主要是JDK)以及最后的启动与测试。以下是详细的步骤: 1. **下载Apache FtpServer**: 首先,...

    Linux下FTP服务器的安装和配置详细.pdf

    Linux 下 FTP 服务器的安装和配置详细 FTP 服务器在 Linux 系统中的安装和配置是一个非常重要的 tema,因为它提供了文件传输协议(FTP)的服务,使用户可以通过 FTP 客户端与远程机器传输文件数据,下载或上传最新...

    Linux下安装卸载ftp的方法

    ftp是liunx下常用的软件之一。 1.将用户切换到root:su - ; 2.检查机器是否已经安装了ftp:rpm -qa|grep vsftpd;  如果没有返回任何结果,表示没有安装;如果返回文件包名,这表示已经安装了该服务; 3.开始安装:...

    linux下搭建ftp服务器

    搭建 Linux 下的 FTP 服务器需要安装 vsFTPd 软件,添加虚拟主机用户,配置 vsFTPd,添加匿名访问,配置 FTP 用户,启动 FTP 服务器,最后测试 FTP 服务器。通过这些步骤,可以成功搭建一个 Linux 下的 FTP 服务器。

    Linux下安装FTP.txt

    ### Linux下安装FTP知识点详解 #### 一、安装VSFTPD服务器 在Linux系统中,安装FTP服务通常采用VSFTPD(Very Secure FTP Daemon),它是一款高性能、安全且功能丰富的FTP服务器程序。以下是在Red Hat Linux 9.0...

    linux下ftp客户端.zip

    linux下 ftp shell ,ftp客户端安装ftp-0.17-54.el6.x86_64.rpm 下载后,解压,上传rpm包到/usr/local/src下,执行rpm -ivh ftp-0.17-54.el6.x86_64.rpm(同时也要安装好vsftpd,查看service vsftpd status运行状态...

    linux 下ftp服务器配置

    linux 下ftp服务器配置 linux 下ftp服务器配置

    Linux下FTP服务器的建立

    FTP(File Transfer Protocol)与WEB一样,在众多网络应用中有着非常重要的地位。据专家统计表明,FTP与WEB服务几乎占据了整个Internet应用的80%以上。...本例介绍了在Linux下建立局域网FTP服务器的基本方法。

    Linux的Ftp服务器搭建的个人总结

    总结,Linux上的FTP服务器搭建涉及多个步骤,包括选择和安装服务器软件、配置服务器参数、创建用户以及确保安全。理解并熟练掌握这些步骤,可以有效地管理和维护FTP服务器。在实际应用中,应根据具体需求进行调整,...

    Linux搭建FTP服务器实现匿名上传.doc

    Linux 搭建 FTP 服务器实现匿名上传 Linux 操作系统中搭建 FTP 服务器可以实现匿名上传文件的功能。FTP(File Transfer Protocol)是一种标准的网络协议,用于在网络上进行文件传输。Linux 操作系统提供了多种 FTP ...

    Linux上安装ftp

    在Red Hat Enterprise Linux 5上安装和配置FTP服务器,我们通常选择使用vsftpd(Very Secure FTP Daemon),因为它以其安全性和高效性而闻名。以下是安装和配置vsftpd的详细步骤,以及关于其配置文件和相关目录的...

    Linux下FTP服务器的安装和配置(详细)

    ### Linux下FTP服务器的安装和配置(详细) #### 一、概述 FTP(File Transfer Protocol,文件传输协议)是一种用于在网络上进行文件传输的标准协议。它允许用户在一个主机上登录到另一台主机上,并且能够传输文件。...

    linux下ftp配置

    Linux 下 FTP 服务器配置是指在 Linux 操作系统下安装、配置和启动 FTP 服务器,以便用户可以通过 FTP 客户端上传、下载文件。FTP 服务器是一种常用的网络服务,允许用户通过 Internet 访问和管理服务器上的文件。 ...

    linux下搭建ftp服务器实验报告借鉴.pdf

    Linux 下搭建 FTP 服务器实验报告借鉴 本实验报告旨在指导读者在 Linux 系统下搭建 FTP 服务器,熟练运用 FTP 服务器,并掌握 FTP 服务器的配置和使用。 一、实验目的 本实验的目的是让读者掌握在 Linux 系统下...

    linux下ftp服务器建设

    ### Linux下FTP服务器建设知识点详解 #### 一、实验说明:Vsftpd介绍与特性 在Linux环境下搭建FTP服务器时,通常会选择Vsftpd作为首选工具。Vsftpd(Very Secure FTP Daemon)是一款专为安全性而设计的FTP服务器...

    ftp.rar_arm ftp_ftp linux_ftp 服务器 linux_ftp服务器源码_linux ftp

    1. 安装FTP服务器软件:在Linux系统上,可以通过包管理器(如apt-get或yum)来安装FTP服务器软件。 2. 配置服务器:编辑服务器配置文件,比如vsftpd的`/etc/vsftpd.conf`,设定用户访问权限、匿名FTP、数据端口等...

    LinuxFTP服务器配置实验报告整理.pdf

    通过本次实验的实践和学习,我们掌握了在 Linux 下 Vsftpd 的安装和配置方法,以及了解了 FTP 服务配置文件的信息内容和功能作用,熟悉了 FTP 客户端工具的使用,同时还掌握了常见 FTP 服务器的故障排除,对 FTP ...

Global site tag (gtag.js) - Google Analytics