http/2 서버 설정기

참고 사이트 : http://macbeese.com/%E3%82%B7%E3%82%B9%E3%83%86%E3%83%A0/centos-7-1-apache-2-4-20-%E7%84%A1%E6%96%99ssl%E3%81%AB%E3%82%88%E3%82%8B-http2-%E3%81%AE%E5%B0%8E%E5%85%A5%E6%96%B9%E6%B3%95

HTTP/2 세팅

  1. openssl 설치한다.

yum install zlib-devel

yum install gcc

yum install gcc-c++

wget https://www.openssl.org/source/openssl-1.1.0e.tar.gz

tar xvzf openssl-1.1.0e.tar.gz

cd openssl-1.1.0e

아직은 1.1.0e 가 지원되지 않는듯…

wget https://www.openssl.org/source/openssl-1.0.2k.tar.gz

tar xvzf openssl-1.0.2k.tar.gz

cd openssl-1.0.2k

./config —prefix=/usr/local/openssl shared zlib

make

make install

echo /usr/local/openssl/lib > /etc/ld.so.conf.d/openssl.conf

ldconfig

/usr/local/openssl/bin/openssl

OpenSSL> version

OpenSSL 1.1.0e  16 Feb 2017

nghttp2 설치

yum install libev-devel

wget https://github.com/nghttp2/nghttp2/releases/download/v1.22.0/nghttp2-1.22.0.tar.gz

tar xvzf nghttp2-1.22.0.tar.gz

cd nghttp2-1.22.0

env OPENSSL_CFLAGS=“-I/usr/local/openssl/include” OPENSSL_LIBS=“-L/usr/local/openssl/lib -lssl -lcrypto” ./configure

make

make install

echo /usr/local/lib > /etc/ld.so.conf.d/usr-local-lib.conf

ldconfig

wget http://ftp.kaist.ac.kr/Apache/apr/apr-1.5.2.tar.gz

tar xvzf apr-1.5.2.tar.gz

cd apr-1.5.2

./configure

make

make install

wget http://ftp.kaist.ac.kr/Apache/apr/apr-util-1.5.4.tar.gz

tar xvzf apr-util-1.5.4.tar.gz

cd apr-util-1.5.4

./configure –with-apr=/usr/local/apr

make

make install

yum install pcre-devel

최신 아파치를 가져온다.

wget http://apache.tt.co.kr/httpd/httpd-2.4.25.tar.gz

tar xvzf httpd-2.4.25.tar.gz

cd httpd-2.4.25

./configure –enable-http2 –enable-ssl –with-ssl=/usr/local/openssl –with-apr=/usr/local/apr –with-apr-util=/usr/local/apr/bin/apu-1-config –enable-so –enable-mpms-shared=all

make

make install

답글 남기기