Apache Web Server Setup Tutorial

Source: Internet
Author: User
Tags file system linux

Creating a Web server under Linux can choose Netscape's Enterprise Server or use Apache, the free software. Netscape can fully support ip-based virtual hosts, but it does not support domain-based virtual hosts, so only the outermost layer of Web pages can be displayed. Ip-based virtual host requires a separate IP; A domain-based virtual host can share an IP with multiple virtual hosts. Using the HTTP 1.1 protocol, depending on the domain name to differentiate can greatly save IP address resources. Apache fully supports both of these virtual host methods and overcomes the frequent service stopper of Netscape. Apache is currently a widely used Web server on the Internet. Here's how to use Apache to set up your own Web server.

Installation

First we want to introduce the Apache installation process.

First, go to http://www.apache.org to download the latest version of Apache. If it is under Windows, download the file in C, the C disk corresponds to/DEV/HDA1 in Linux.

Second, go to Linux and log in as root and hook up the file system.

# mkdir C
# mount-t VFAT/DEV/HDA1/C

Because we put the Apache source in the C disk, we now have to mount it to the new directory/C.

Third, copy this program to/TMP for operation.

#cp/c/apache_1.3.9.tar.gz/tmp

Note: All filenames under Linux are case-sensitive. Next, we need to extract the source code from the compression package. The corresponding commands are:

#cd/tmp
#tar ZXVF apache_ 1.3.9.tar.gz

After decompression, enter the directory where the source is stored, and use the compile configuration script to set up the environment.

#cd/tmp/apache_1.3.9
#./configure--sysconfdir=/etc/httpd
--datadir=/home/httpd
--logfiledir=/var/log/httpd
--enable-module=most
--enable-shared=max
--disable-rule= Wanthsregex

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.