Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Server \ Ubuntu 14.04 compile and install Apache     - Linux foreground to background process switch (Linux)

- Installation Flow N Play- interface stylized video player on Ubuntu (Linux)

- Cobbler batch install Ubuntu / CentOS system (Linux)

- Use of the storage-level replication technology will quickly clone a ASM database to the target environment (Database)

- Android thread mechanism --AsyncTask (Programming)

- Disk Management LVM (Linux)

- Hadoop 2.7.1 Installation and Configuration under RedHat Linux 6.5 (Server)

- Virtualbox virtual machine can not copy CentOS Network (Linux)

- Testing Oracle 11g RMAN replicate database (Database)

- Linux firewall to prevent external network attacks (Linux)

- With screenfetch linux logo and basic hardware information display with cool Linux logo (Linux)

- MySQL configuration file my.cnf increase the log file parameter error (Database)

- Distributed Firewall Design on Linux platform (Linux)

- Linux vi command list (Linux)

- exp / imp Export Import version of the problem and the ORA-6550 error (Database)

- Optimized to minimize the installation of CentOS 5.8 (Linux)

- Multipath configuration under Linux (Linux)

- How to extend / remove swap partitions (Linux)

- MySQL & NoSQL - Memcached widget (Database)

- Postmodern systems programming language (Programming)

 
         
  Ubuntu 14.04 compile and install Apache
     
  Add Date : 2018-11-21      
         
         
         
  Ubuntu install apache compiler need to install multiple dependent precompiled device comprising: apr, apr-util, pcre, zlib-devel, etc., it is quite troublesome to record this for future reference.

Since Ubuntu system is not installed by default when you install C ++, so you need to install c ++ compiler needs related components.

[Note] apt-cache policy package names // View Installed package information.
Installation steps:

1, first install the c ++ compiler-related components:

Just packed Ubuntu systems have GCC, but the GCC what documents are not translated, because without some necessary header files, so you want to install the build-essential package, the installation of this package will be automatically installed on g ++, libc6 -dev, linux-libc-dev, libstdc ++ 6-4.1-dev and some other necessary software libraries and header files.

Install the required packages:

sudo apt-get install build-essential

2, compiled and installed APR

(1) download apr: Address: http: //mirror.esocc.com/apache/apr/

Storage location: /usr/local/src/apr-1.5.1.tar.gz

(2) #cd / usr / local / src

(3) #tar -zxvf apr-1.5.1.tar.gz

(4) #cd apr-1.5.1

(5) #. / Configure -prefix = / usr / local / apr

(6) #make

(7) #make install

3, and then compile and install apr-util, similar to the previous step to install apr

(1) download apr-util: Address with apr: http: //mirror.esocc.com/apache/apr/

Storage location: /usr/local/src/apr-util-1.5.3.tar.gz

(2) #cd / usr / local / src

(3) #tar -zxvf apr-util-1.5.3.tar.gz

(4) #cd apr-util-1.5.3

(5) #. / Configure -prefix = / usr / local / apr-util --with-apr = / usr / local / apr // here put apr installation path

(6) #make

(7) #make install

4, and then compile and install pcre

(1) download pcre: Address: http: //sourceforge.net/projects/pcre/files/pcre/

Storage location: /usr/local/src/pcre-8.35.tar.gz

(2) #cd / usr / local / src

(3) #tar -zxvf pcre-8.35.tar.gz

(4) #cd pcre-8.35

(5) #. / Configure -prefix = / usr / local / pcre

(6) #make

(7) #make install

5, install zlib-devel

# Apt-get install zlib1g-dev

// Zlib-devel is a RedHat / Fedora name, zlib1g-dev and libz-dev are the Debian / Ubuntu names (zlib1g-dev provides libz-dev which is a virtual package).

or:

(1) Download zlib: Address: http: //sourceforge.net/projects/libpng/files/zlib/

Storage address: / home / xxx / Downloads

#cp /home/xxx/Downloads/zlib-1.2.8.tar.gz / usr / local / src

#cd / usr / local / src

#tar -zxvf zlib-1.2.8.tar.gz

#cd zlib-1.2.8

#. / Configure -prefix = / usr / local / zlib

#make && make install

6, and finally compile and install apache

(1) download apache, address: http: //httpd.apache.org/download.cgi

Storage location: / home / xxx / Downloads

#cd / home / xxx / Downloads

#cp httpd-2.4.9.tar.gz / usr / local / src

#cd / usr / local / src

#tar -zxvf httpd-2.4.9.tar.gz // decompression

#cd httpd-2.4.9

#. / Configure -prefix = / usr / local / apache2 --enable-deflate --enable-expires --enable-headers --enable-modules = most --enable-so --with-mpm = worker --enable -rewrite --with-apr = / usr / local / apr --with-apr-util = / usr / local / apr-util --with-pcre = / usr / local / pcre

#echo $? // Check for errors

# 0 // return 0 no problem

#make

#make install

The above ./cofigure next parameter:

# --prefix = < Install_Path > specified compiled binary files are installed to < Install_Path > directory, replaced with the actual installation path < Install_Path >, such as --prefix = / usr / local / apache-2.4.9, if you omit this configuration parameters, installed by default to / usr / local / apache2.

# --enable-So specified compiled dynamically loaded modules (DSO) support to the httpd binary, so that each module can function module Apache core separately compiled, dynamically loaded at runtime. With the DSO support, upgrades and additional modules can only compile the modules without having to recompile the entire system. The latest version of this module is to compile Apache default httpd binary file, if you are using an earlier version of apache DSO and need support, you may want to clear that option.

# --enable-Mods-shared = < MODULE-LIST > To clearly indicate DSO compiled modules, < MODULE-LIST > is a space separated list of modules, all, or most, all represented include all modules, most expressed comprising most modules, such as --enable-mods-share = "rewritedeflate", - enable-mods-share = most, the effect is equivalent to more than --enable- < FEATURE > = share

# - With-mpm = < MPM > to select Apache Multi-Processing Module, = {beos | mpmt_os2 event | worker | | prefork} default, prefork Unix system is under processing module, it will run a non-threaded the pre-derived Web server, not suitable for thread-safe libraries, the need to avoid threading system compatibility issues, it is requested that each request independently under the best circumstances MPM, if such a request would not be a problem affect other requests. worker support hybrid multi-threaded multi-process multi-channel processing module, due to the use of threads to handle requests, so it can handle massive requests, and system resources is less than the cost of process-based MPM, at the same time, it also uses a number of processes, each processes have multiple threads to obtain the stability of the process-based MPM. If your system is based on thread-safe, then I recommend the use of worker replacement prefork, it makes you get the actual system performance improvement.
     
         
         
         
  More:      
 
- CentOS set up FTP server (Server)
- Memcached installation, configuration and monitoring (Server)
- Resolve the host via KVM console can not connect clients (Linux)
- Install Websphere MB required system rpm package under Linux (Linux)
- Oracle 11g principle study Dataguard (Database)
- Intel Graphics Installer installation on Ubuntu 15.10 (Linux)
- To install PostgreSQL 9.4 (Database)
- Learning the Linux powerful network management capabilities (Linux)
- PostgreSQL-- run Supervisord on Docker in Ubuntu (Database)
- Weld a problem in JDK 8u60 environment (Programming)
- GNU Linux system variables (sysctl configuration commands) integrated use (Linux)
- Will Laravel become the most successful PHP framework? (Programming)
- RHEL 6.5 x86_64 CentOS yum configuration source (Linux)
- Use UDEV SCSI Rules configured ASM on Oracle Linux 5 and 6 (Database)
- Linux formatted partition error Could not stat / dev / sda No such file or directory Solution (Linux)
- Getting Started with Linux: Learn how to upgrade Docker in Ubuntu (Server)
- iTerm - let your command line can also be colorful (Linux)
- Linux Oracle environment variable is invalid Problem Solving (Database)
- Linux Getting Started tutorial: hard disk partition and to deal with traps (Linux)
- Cobbler batch install Ubuntu / CentOS system (Linux)
     
           
     
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.