Apache 2.4.39 소스 설치
조건 : CentOS 7.6.1810 (minimal ) 만 설치
네트워크 환경
cd /usr/local/src/
yum -y install wget openssl-devel gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel krb5 krb5-devel libidn libidn-devel openssl openssl-devel libtool libtool-libs openldap openldap-devel nss_ldap openldap-clients openldap-servers libtool-ltdl libtool-ltdl-devel bison expat-devel
yum -y groupinstall "Development Tools"
yum -y install gd gd2 gd-devel gd2-devel wget pcre* openssl* perl libaio
wget http://apache.tt.co.kr//httpd/httpd-2.4.39.tar.bz2
wget http://apache.tt.co.kr/apr/apr-1.6.5.tar.gz
wget http://apache.tt.co.kr/apr/apr-util-1.6.1.tar.gz
tar jxvf httpd-2.4.39.tar.bz2
tar xvf apr-1.6.5.tar.gz
tar xvf apr-util-1.6.1.tar.gz
mv apr-1.6.5 apr
mv apr httpd-2.4.39/srclib/
mv apr-util-1.6.1 apr-util
mv apr-util httpd-2.4.39/srclib/
cd httpd-2.4.39
## 커스텀 튜닝 부분입니다. 최소한의 부분이니 그냥 써도 무방합니다.
sed -i "s/finished(outctx->filter_ctx->pssl)/finished(outctx->filter_ctx->pssl);/g" ./modules/ssl/ssl_engine_io.c
perl -pi -e "s/LIMIT 256/LIMIT 2048/g" server/mpm/prefork/prefork.c
perl -pi -e "s/LIMIT 16/LIMIT 128/g" server/mpm/worker/worker.c
## 컨피그입니다. ssl과 all-shared 부분만 있으면 보통 큰 문제 없음.
./configure --prefix=/usr/local/apache2 --enable-module=so --enable-mods-shared=all --enable-so --enable-deflate --enable-rewrite --with-included-apr --enable-module=ssl --enable-ssl=shared --with-ssl --enable-ssl --with-mpm=prefork
make -j 3
make install
## lib 라이브러리 PATH 설정
echo "/lib" >> /etc/ld.so.conf
echo "/usr/lib" >> /etc/ld.so.conf
echo "/usr/local/lib" >> /etc/ld.so.conf
echo "/usr/local/mysql" >> /etc/ld.so.conf
echo "/usr/local/mysql/lib" >> /etc/ld.so.conf
echo "/usr/local/apache2/lib" >> /etc/ld.so.conf
시작 경로는 컨피그 보면 알겠지만
/usr/local/apache2/bin/apachectl 입니다.
2.4는 SSL 엔진 적용을 하더라도 굳이 -D SSL -k start 옵션 줄 필요가 없음.
'Linux ( Cent OS ) > Apache' 카테고리의 다른 글
[설치] 3. PHP 7.3.4 Source Install (0) | 2019.04.18 |
---|---|
[설치] 2. MySQL 5.7.25 Source Install (1) | 2019.04.18 |