Help us understand the problem. What are the problem?

More than 5 years have passed since last update.

posted at

updated at

How to install nghttp2, h2load on OracleLinux 6.7

How to install nghttp2, h2load on OracleLinux 6.7

- :white_check_mark: install HTTP/2 server nghttp2
- :white_check_mark: install HTTP/2 benchmark tool h2load


centos6 だと epel の libev が古くてめんどくさくなったので centos7 でビルドした

So let me try...


  • OracleLinux 6.7 installed (Red Hat Enterprise Linux Server 6.7)
Oracle Linux Server release 6.7

Building from git

Building from git is easy, but please be sure that at least autoconf 2.68 is used:
$ autoreconf -i
$ automake
$ autoconf
$ ./configure
$ make

To compile the source code, gcc >= 4.8.3 or clang >= 3.4 is required.

Before compile ... required libraries

yum groupinstall "Development tools"
git clone https://github.com/tatsuhiro-t/spdylay.git
git clone https://github.com/tatsuhiro-t/nghttp2.git

more spdylay/README.rst
more nghttp2/README.rst

:exclamation: gcc -v
gcc version 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC)

We need to install newer gcc as well as Python 2.7 -
Installing Software Collection Library Utility from Oracle Public Yum

# wget -O /etc/yum.repos.d/public-yum-ol6.repo http://public-yum.oracle.com/public-yum-ol6.repo

name=Software Collection Library release 1.2 packages for Oracle Linux 6 (x86_64)
yum install scl-utils
yum install devtoolset-3 python27

scl enable devtoolset-3 python27 bash

wget ftp://ftp.gnu.org/pub/gnu/autoconf/autoconf-2.64.tar.gz
tar zxvf autoconf-2.64.tar.gz
cd autoconf-2.64
make install
autoconf --version
wget ftp://xmlsoft.org/libxml2/libxml2-2.7.7-1.x86_64.rpm
wget ftp://xmlsoft.org/libxml2/libxml2-devel-2.7.7-1.x86_64.rpm
wget ftp://xmlsoft.org/libxml2/libxml2-python-2.7.7-1.x86_64.rpm
yum -Uvh libxml2-*

wget ftp://ftp.pbone.net/mirror/ftp5.gwdg.de/pub/opensuse/repositories/home:/rudi_m/RedHat_RHEL-6/x86_64/libev4-4.15-7.1.x86_64.rpm
wget ftp://ftp.pbone.net/mirror/ftp5.gwdg.de/pub/opensuse/repositories/home:/rudi_m/RedHat_RHEL-6/x86_64/libev-devel-4.15-7.1.x86_64.rpm
yum -Uvh libev*

Now make install

cd spdylay

autoreconf -i
make install
cd ../nghttp2
export PKG_CONFIG_PATH=/lib/pkgconfig:/usr/lib/pkgconfig:/usr/lib64/pkgconfig:/usr/local/lib/pkgconfig
autoreconf -i
./configure --with-spdylay
make install

Done :smiley: :tada:


The following package is required to build the libnghttp2 library:

  • pkg-config >= 0.20

To build and run the unit test programs, the following package is required:

  • cunit >= 2.1

To build the documentation, you need to install:

To build and run the application programs (nghttp, nghttpd,nghttpx and h2load) in the src directory, the following packages are required:

  • OpenSSL >= 1.0.1
  • libev >= 4.15
  • zlib >= 1.2.3

ALPN support requires OpenSSL >= 1.0.2 (released 22 January 2015).
LibreSSL >= 2.2.0 can be used instead of OpenSSL, but OpenSSL has more features than LibreSSL at the time of this writing.

To enable the SPDY protocol in the application program nghttpx and h2load, the following package is required:

  • spdylay >= 1.3.2

To enable -a option (getting linked assets from the downloaded resource) in nghttp, the following package is required:

  • libxml2 >= 2.7.7

The HPACK tools require the following package:

  • jansson >= 2.5

To build sources under the examples directory, libevent is required:

  • libevent-openssl >= 2.0.8

To mitigate heap fragmentation in long running server programs (nghttpd and nghttpx), jemalloc is recommended:

  • jemalloc

libnghttp2_asio C++ library requires the following packages:

  • libboost-dev >= 1.54.0
  • libboost-thread-dev >= 1.54.0

The Python bindings require the following packages:

  • cython >= 0.19
  • python >= 2.7
  • python-setuptools
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Sign upLogin
Help us understand the problem. What are the problem?