linux-apache-Configuring installation and debugging steps

Source: Internet
Author: User

Happy original. Daily Notebooks

linux-6.5, apache-httpd-2.2.17. System software version


The first step is to see if Linux has installed httpd, otherwise there will be minor conflicts, but can be modified later

RPM-E httpd--nodeps

--nodeps ignore dependencies and force uninstallation.


Mount Apache Software

Mount/dev/cdrom/media


Extract Apache, specify extract directory/usr/src

Tar zxf/media/httpd-** version different names are different-c/usr/src

into the Unzip directory

cd/usr/src/httpd-***


Configure Apache, configure parameters, require functions, etc.

./configure

--PREFIX=/USR/LOCAL/HTTPD [Specify installation directory]

--enable-so [Enable dynamic load module support, increase expansion capability]

--enable-rewrite [web address rewriting, for optimization, migration, maintenance]

--enable-charset-lite [Launch character set, support for various character set encoding pages]

--enable-cgi [Enable CGI scripts, extend website app access]


Compiling && Installation

Make && make install


Apache Post-optimization

Ln-s/usr/local/httpd/bin/*/usr/local/bin/

is actually a soft connection, equivalent to a shortcut in Windows

Httpd-v viewing the current version of Apache


Add Apache to system service

Cp/usr/local/httpd/bin/apachenctl/etc/init.d/httpd

Copy run software to system service, modify the configuration file to use Chkconfig

Vim/etc/init.d/httpd

Change three lines of information after entering

#!/bin/bash

# CHKCONFIG:35 85 21 Service identification parameter 35 class start, what's the order

#description: Write casually. The equivalent of remarks, must also have

Chkconfig--add httpd Add httpd for system service

Chkconfig--list httpd View the startup status of the HTTPD service

-------------------------------------above is the installation of Apacheweb service completed-------

------------------------------below to begin the detailed configuration of Apache-------------------------

You can modify the Web site name of the default domain name

Vim/usr/local/httpd/conf/httpd.conf

The servername server name is found in the edit httpd master configuration file

ServerName www.*****.com domain name to write their own, in front of the # delete can be

/usr/local/httpd/bin/apachectl-t [view detection for syntax errors]


Service httpd start [Apache service started because the installation was added as a system service]


cat/usr/local/httpd/htdocs/index.html View this document

This document is the default homepage of the Web page, should be it works information


Need the website to do better can modify the information in httpd.conf

Domain name resolution IP needs to install its own DNS configuration, which is not described here.

2016-9-9-Notebooks


This article is from the "11627223" blog, please be sure to keep this source http://11637223.blog.51cto.com/11627223/1907035

linux-apache-Configuring installation and debugging steps

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.