Enable Mod_HTTP2 for Apache in CWP


Upgrade Openssl

cd /usr/local/src
wget https://www.openssl.org/source/openssl-1.1.0h.tar.gz
tar zxvf openssl-1.1.0h.tar.gz
cd openssl-1.1.0h
./config --prefix=/usr --openssldir=/usr/lib64 shared
make
make install

Upgrade Autoconf

cd /usr/local/src
wget https://ftp.gnu.org/gnu/autoconf/autoconf-latest.tar.gz
tar zxvf autoconf-latest.tar.gz
cd autoconf-*
./configure --prefix=/usr
make
make install

 

Install Nghttp2

cd /usr/local/src
yum install libtool libuuid-devel libuuid -y
git clone https://github.com/nghttp2/nghttp2.git
cd nghttp2
autoreconf -i
automake
autoconf
./configure --prefix=/usr
make
make install

 

Compile Apache

Navigate to/admin/index.php?module=apache_builder

 

 

Select Select NEW Apache version: and click Next

 

In Additional configuration (only for advanced users): enter --enable-http2 and click on Start Compiler in Background

 

Enable Mod_http2 Module

Copy and paste all lines not one by one

cat > /usr/local/apache/conf.d/mod_http2.conf << "EOF"
LoadModule http2_module modules/mod_http2.so
<IfModule http2_module>
LogLevel http2:info
Protocols h2 h2c http/1.1
</IfModule>
EOF

 

Restart Apache

service httpd restart

Bullten

A company providing web hosting solutions around globe...