In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "how to build ftp server and configuration under linux". In daily operation, I believe many people have doubts about how to build ftp server and configuration under linux. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful to answer the doubts about "how to build ftp server and configuration under linux". Next, please follow the editor to study!
First of all, proftpd is an open source software, the highest version is 1.3.1 (unstable version), the stable version is 1.3.0, and the download file is proftpd-1.3.0a.tar.gz.
I downloaded 1.3.0, upload it to the server and install it according to the usual method.
Tar-zxvf proftpd-1.3.0a.tar.gz
Cd proftpd*
. / configure-- prefix=/usr/local/proftpd
Make
Make install
Installation complete! Next is the configuration.
Setting 1: randomly start the service, copy the sbin/proftpd file to the / etc/rc.d/rc.local folder to achieve automatic startup.
Setting 2: the configuration file is in etc/proftpd.conf. The configuration file is described as follows:
ServerName "ProFTPD Default Installation"
ServerType standalone
DefaultServer on
Respectively represents: server name, service type and default service status!
I will omit the back service port, ah, and talk about the most critical access control part.
# Set the user and group under which the server will run.
User nobody
Group nogroup
Pay attention to the above: under which users and groups to run the service.
Change to your existing groups and users. For administrative convenience and security considerations, it is recommended to create a new ftp group and ftp users.
# To cause every FTP user to be "jailed" (chrooted) into their home
# directory, uncomment this line.
# DefaultRoot ~
Whether the user is allowed to enter the user's home directory, note: however, / home substitution is applicable.
# Normally, we want files to be overwriteable.
AllowOverwrite on
Do you have the right to rewrite
# A basic anonymous configuration, no upload directories. If you do not
# want anonymous users, simply delete this entire section.
User ftp
Group ftp
# We want clients to be able to login with "anonymous" as well as "ftp"
UserAlias anonymous ftp
# Limit the maximum number of anonymous logins
MaxClients 10
# We want 'welcome.msg' displayed at login, and' .message 'displayed
# in each newly chdired directory.
DisplayLogin welcome.msg
DisplayFirstChdir .message
# Limit WRITE everywhere in the anonymous chroot
DenyAll
This part of the definition of anonymous users is actually very simple.
Unable to start, the solution to the following error occurs
[root@new-host sbin] #. / proftpd
-IPv4 getaddrinfo 'new-host' error: Name or service not known
-warning: unable to determine IP address of 'new-host'
-error: no valid servers configured
-Fatal: error processing configuration file'/ usr/local/proftpd/etc/proftpd.conf'
The reason is that the Ip address cannot be bound.
Add the following sentence to the configuration file:
DefaultAddress 192.168.8.105
Just restart the service again!
Put it on! Originally thought this is done, but look at it to know that if I want to add a new FTP user is actually a very troublesome thing, because the account is directly associated with the system account, not safe and not easy to operate, our goal is to make a ftp like a virtual hosting service provider!
Next, you need a module support to take a look at the proftpd-mod-quotatab module and note the following sentence:
NOTE: mod_quotatab became part of the offical ProFTPD source distribution in 1.2.10rc1. If using a version of ProFTPD later than that, please use the mod_quotatab already included, as it will be most up-to-date.
It means that the 1.3 version we downloaded has already supported this thing, so we can just turn on mod_quotatab when compiling and installing it, so recompile it!
Premise: make sure you have installed and can run mysql properly, otherwise the rest of the work will be meaningless!
Recompile:
. / configure-prefix=/usr/local/proftpd-with-modules=mod_sql:mod_sql_mysql:mod_quotatab:mod_quotatab_sql-with-includes=/usr/include/mysql-with-libraries=/usr/lib/mysql
Note that according to your own Linux system, please find the corresponding include and lib directories of MySQL. The relevant paths in the above examples are the default of most Linux systems. If your MySQL is installed through source code compilation, these two directories are generally under the installation path.
At this point, the study on "how to build a ftp server and configuration under linux" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.