Post: how to provide personal homepage space services in RedHat 7.2 Linux

Source: Internet
Author: User
In Linux, Apache and wu-ftpd servers can be used to implement personal space services through some simple settings. Apache is a web server and FTP provides the Home Page upload function. this article takes RedHat 7.2 Linux as an example. Assume that Apache and wu-ftpd servers have been installed. The specific configuration method is as follows:

(1) When installing redhat7.2 Linux, select "server" or install the server software;

(2) modify the section about personal space settings in the/etc/httpd/CONF/httpd. conf file (// is described in detail later)

Userdir public_html // modify the default directory, which can be modified.

// Corresponds

#

# Control access to userdir directories. The following is an example

# For a site where these directories are restricted to read-only.

#

#//

# AllowOverride fileinfo authconfig limit

# Options Multiviews indexes symlinksifownermatch IncludesNOEXEC

#

# Order allow, deny

# Allow from all

#

#

# Order deny, allow

# Deny from all

#

#//..... Remove all # between rows to make the settings of personal homepage users take effect. in addition, "/home/*/public_html" in "is the setting of the storage location of the personal homepage service in Linux * represents the directory name generated by the user name.

Restart the HTTPd service: httpd stop/httpd start or httpd restart

(3) add an FTP user's shell so that it cannot use commands, and telnet and SSH services

Edit the/etc/shells file and add a line of "/dev/null" at the end of the file.

(4) add an ftpchroot family. In the reorganization, the user uses the home directory as the FTP root directory.

Groupadd ftpchroot

(5) When a user applies for a personal homepage space, the user name used should be the ftpchroot group user on Linux. The following operations take the test user as an example:

Create a user test; Password: Test

Usradd test-S/dev/null-G ftpchroot

Passwd Test

In this way, a test directory is automatically generated under the/home directory.

(6) Go to the test directory, create the publish directory public_html on the personal homepage, and set the permissions.

CD/home/test

Mkdir public_html

Chmod 711/home/test

Chmod 755/home/test/public_html

Hosts file.

Note: If the server system is fully installed, the php jsp dynamic web page and MySQL PostgreSQL database can be supported on the personal homepage.

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.