Build your own website 1--How to install Apache Server

Source: Internet
Author: User
Tags unpack fully qualified domain name

Operating System:ubuntu 16.04

Web Server? Most often used Web server software is freely available Apache Server. Download Apache for free? Https://httpd.apache.org/download.cgi#apache24

Unpack httpd-2.4.29.tar.bz2 to ~/downloads/httpd-2.4.29

Download apr-1.6.3.tar.bz2 and apr-util-1.6.1.tar.bz2 from http://apr.apache.org/download.cgi and unpack them to ~/ DOWNLOADS/HTTPD-2.4.29/SRCLIB/APR and ~/downloads/httpd-2.4.29/srclib/apr-util respectively.

Install Apache using the commands below

./configure--prefix=/usr/local/apache2--with-included-apr=truemakemake Install

The installation takes several minutes. After this, you can start Apache server using

/usr/local/apache2/bin/apachectl start

It'll warn you

AH00558:httpd:Could not reliably determine the server ' s fully qualified domain name, using 127.0.1.1. Set the ' ServerName ' directive globally to suppress this message

This was a friendly warning and not an error. You can launch a browser and visit http://127.0.1.1 and a simple webpage saying "It works!" appears. The default document root Is/usr/local/apache2/htdocs/where we can put a hello_world.html and this HTML file ' s address Is http://127.0.1.1/hello_world.html

If you want to turn off the server, Run command

/usr/local/apache2/bin/apachectl stop

The same warning appears

Build your own website 1--How to install Apache Server

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.