The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

HTTP/2 and WHM 58 with EA4

Discussion in 'Workarounds and Optimization' started by RWH Tech, Aug 18, 2016.

  1. RWH Tech

    RWH Tech Well-Known Member

    Joined:
    Oct 1, 2015
    Messages:
    74
    Likes Received:
    11
    Trophy Points:
    8
    Location:
    Brazil
    cPanel Access Level:
    Root Administrator
    Tested on a clean and dirty CentOS 7 install and running production on a small server for a few weeks now (~20 sites).

    Will probably give you cancer.
    If you want symlink protection, you’ll need to edit SPECS/ea-apache24.spec, search for 401 or 402 and uncomment TWICE in it, depending on what you want to use.
    The rack911 patch does not require apr to be modified from stock, so you can skip it.

    Code:
    mkdir /root/rpmbuild
    cd /root/rpmbuild
    yum -y install rpm-build
    mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
    echo ‘%_topdir %(echo $HOME)/rpmbuild’ > ~/.rpmmacros
    mkdir poop
    git clone https://github.com/Cacasapo/ea-apache2-http2.git poop
    mv poop/SOURCES/find.pl /usr/lib64/perl5
    mv poop/SOURCES/042_mod_http2.conf /etc/apache2/conf.modules.d
    \cp -R poop/SPECS/* SPECS/
    \cp -R poop/SOURCES/* SOURCES/
    rm -fr poop
    
    #skip if not using Bluehost
    git clone https://github.com/Cacasapo/apr.git poop1
    \cp -R poop1/SPECS/* SPECS/
    \cp -R poop1/SOURCES/* SOURCES/
    rm -fr poop1
    
    #openssl depend
    yum -y install perl-WWW-Curl
    #apr depend
    yum -y install lksctp-tools-devel
    #apache depend
    yum -y install xmlto lua-devel ea-apr-devel ea-apr-util-devel
    
    yum -y install createrepo
    mkdir /root/repo
    
    nano /etc/yum.repos.d/local.repo
    [local]
    name=CentOS-$releasever - local packages
    baseurl=file:///root/repo
    enabled=1
    gpgcheck=0
    protect=1
    cost=20
    priority=1
    
    #OpenSSL
    rpmbuild -ba SPECS/openssl.spec
    \cp RPMS/x86_64/openssl-parallel* ../repo
    createrepo /root/repo
    yum clean expire-cache
    yum -y install openssl-parallel
    
    #Do nghttp2
    rpmbuild -ba SPECS/nghttp2.spec
    \cp RPMS/x86_64/libng* ../repo
    \cp RPMS/x86_64/nghttp* ../repo
    createrepo /root/repo
    yum clean expire-cache
    yum -y install libnghttp2-devel
    
    #Do apr IF USING BLUEHOST PATCH
    rpmbuild -ba SPECS/ea-apr.spec
    \cp RPMS/x86_64/ea-apr* ../repo
    createrepo /root/repo
    yum clean expire-cache
    yum -y install ea-apr ea-apr-devel
    
    #Do apache
    rpmbuild -ba SPECS/ea-apache24.spec
    \cp RPMS/x86_64/ea-apache24* ../repo
    createrepo /root/repo
    yum clean expire-cache
    yum -y install ea-apache24
    
    #Suhosin spec is in there. You know what needs done, by now.
    # Remember to create the ini in the php 56 config dir.
    
     
    #1 RWH Tech, Aug 18, 2016
    Last edited: Aug 18, 2016
    eva2000 and cPJacob like this.
  2. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,482
    Likes Received:
    203
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Please feel free to post your workaround for this, on this forum. Link removed.
     
  3. RWH Tech

    RWH Tech Well-Known Member

    Joined:
    Oct 1, 2015
    Messages:
    74
    Likes Received:
    11
    Trophy Points:
    8
    Location:
    Brazil
    cPanel Access Level:
    Root Administrator
    Done!
     
  4. RWH Tech

    RWH Tech Well-Known Member

    Joined:
    Oct 1, 2015
    Messages:
    74
    Likes Received:
    11
    Trophy Points:
    8
    Location:
    Brazil
    cPanel Access Level:
    Root Administrator
    HEADS UP.

    If you use mod_http2 with Magento 2.x or WHMCS with RCM, you will need to insert H2StreamMaxMemSize 512000 into to your /etc/apache2/conf.modules.d/042_mod_http2.conf

    Magento 2.x's issue was fixed by 128000, but WHMCS's Resellerclubmod promo page hung, so I increased it to 256, then 512.

    If you do not do this, you will not be able to reliably access the "Payment Processor" page and the Magento's backend will hang at random places, as will some of WHMCS's Resellerclubmods pages.

    I'm certain other apps are affected by this. I have not seen any adverse effects due to this increased buffer.
     
    eva2000 likes this.
Loading...

Share This Page