Tutorials

How to Install mod_spdy with Apache on Ubuntu 16.04

Table of Contents

Introduction

Mod_spdy also known as SPeeDY is an open source Apache module that adds support for the SPDY protocol to the Apache server and allows Apache web servers to serve HTTPS requests using the SPDY protocol. Mod_spdy is used to speed up the Web, reduce bandwidth usage, and decrease page load times. Mod_spdy runs over HTTPS connections, so you will need an HTTPS-enabled web site to test mod_spdy.

In this tutorial, we will learn how to install mod_spdy with Apache on Ubuntu 16.04.

Requirements

  • Ubuntu 16.04 server with Apache and PHP installed on your system.
  • Non-root user account with sudo privilege set up on your system.

Getting Started

Let's start making sure that your Ubuntu 16.04 server is fully up to date. You can update your server by running the following command:

sudo apt-get update -y
sudo apt-get upgrade -y

Installing mod_spdy

Mod_spdy was packaged up to Apache 2.2. You will need to compile it from source in order to enable it in Apache 2.4.X.

Let's start by installing required dependencies to compile mod_spdy:

sudo apt-get -y install git g++ libapr1-dev libaprutil1-dev curl patch binutils make devscripts

Next, download mod_spdy source code from git repository:

git clone https://github.com/eousphoros/mod-spdy.git

Change the directory to mod-spdy:

cd mod-spdy/src

Compile mod_spdy and modssl by running the following commands:

sudo ./build_modssl_with_npn.sh
sudo chmod +x ./build/gyp_chromium
sudo make BUILDTYPE=Release

Next, stop Apache service and copy mod_ssl.so from source:

sudo /etc/init.d/apache2 stop
sudo cp mod_ssl.so /usr/lib/apache2/modules

Now, restart Apache service.

sudo /etc/init.d/apache2 restart

Next, enable SSL module and SSL default website by running the following command:

sudo a2enmod ssl
sudo a2ensite default-ssl

Now, create mod_spdy configuration file and enable spdy module by running the following command:

sudo cp out/Release/libmod_spdy.so /usr/lib/apache2/modules/mod_spdy.so
sudo echo "LoadModule spdy_module /usr/lib/apache2/modules/mod_spdy.so" | sudo tee /etc/apache2/mods-available/spdy.load
sudo echo "SpdyEnabled on" | sudo tee /etc/apache2/mods-available/spdy.conf
sudo a2enmod spdy

Finally restart Apache service to make this changes take effect:

sudo /etc/init.d/apache2 restart

Testing Mod_spdy

Now let's test whether mod_spdy is working or not. Open your web browser and type the URL https://server-ip-address and check HTTP response headers in firebug, you should see x-mod-spdy enable in the following image.

mod_spdy test page

Summary

In this tutorial, we have installed and configured the SPDY module for Apache. Now the Apache server can handle HTTPS requests using the SPDY protocol. To test your SPDY module check out https://spdycheck.org/. Feel free to add comments below if you have any issues installing the SPDY module.

 
  • I really like to visit here and share this great blog have to seen the online play spider solitaire that the amazing card game for you create the best score forever.

  • You will be authenticating with CoreOS using SSH keys. To do this you will need to generate a new key or use your existing one. You can follow our tutorial on how to create and setup SSH keys. five nights at freddy's online

  • I knew it was on its way out it was just salt in the wound replacing it with Assignment Spot the dumpster fire that was the Clevand Show. Not the best analogy because I guess dumpster fires might be entertaining to watch occasionally.

Log In, Add a Comment