Learning notes for LINUX-based proftp (1)

Source: Internet
Author: User
Article title: LINUX-based proftp study notes (1 ). Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Before installing proftp, you must first make a job. if your mysql is compiled by yourself, you must first modify/etc/ld. so. conf; otherwise, an error will be reported when you run proftp later.
Vi/etc/ld. so. conf
  
Add the following line:
  
/Usr/local/mysql/lib/mysql
  
Note: If you have different installation paths for mysql, enter the corresponding path. for mysql compilation and installation, see Linux + Apache + Mysql + PHP typical configuration.
  
   1. Download related software
Wget ftp://ftp.proftpd.org/distrib/source/proftpd-1.2.9.tar.gz
Download the latest proftp version 1.2.9
Wget http://www.castaglia.org/proftpd/modules/proftpd-mod-quotatab-1.2.11.tar.gz
This is the disk quota module that works with proftp.
  
   2. Decompress and compile
Tar zvxf proftpd-1.2.9.tar.gz
  
Tar zvxf proftpd-mod-quotatab-1.2.11.tar.gz
  
Cp mod_quotatab/*. c proftpd-1.2.9/contrib/
  
Cp mod_quotatab/*. h proftpd-1.2.9/contrib/
  
Vi proftpd-1.2.9/contrib/mod_ SQL _mysql.c
Find the line # include and change mysql. h to the path of the file in your system, such as/usr/local/mysql/include/mysql. h.
  
Compile:
  
./Configure
-- Prefix =/usr/local/proftpd
-- With-modules = mod_ SQL: mod_ SQL _mysql: mod_quotatab
: Mod_quotatab_ SQL: mod_ratio
-- With-primary des =/usr/local/mysql/include/mysql
-- With-libraries =/usr/local/mysql/lib/mysql
Make
Make install
  
  
Here we have added support for mysql, quota, ratio, and other modules during compilation. I will talk about their applications later.
  
Now we can start proftp, as long as/usr/local/proftpd/sbin/proftpd
Use your ftp client to test the following and you should be able to log on normally, including anonymous and linux user names.
  
In fact, the default proftp is more than enough for daily server management. You still need to modify it, that is, the default proftp configuration file does not support ftp resume, so we only need vi/usr/local/proftpd/etc/proftpd. conf
  
Add the following two lines
  
AllowRetrieveRestart on
AllowStoreRestart on
Restart the following proftp to resume the file.
  
Create a proftpd script
  
As long as the source code directory in proftp
  
Proftpd-1.2.9/contrib/dist/rpm/proftpd. init. d/etc/rc. d/init. d/proftpd
  
Remember to modify the proftpd file. Generally, you need to modify the actual path of proftpd.
  
Chmod 755/etc/rc. d/init. d/proftpd
OK
  
You can use this tutorial to start, stop, and restart proftp later.

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.