Would you like to learn how to install the Apache traffic server as a reverse proxy on Ubuntu Linux? In this tutorial, we are going to show you all the steps required to perform the Apache traffic server installation on Ubuntu Linux in 5 minutes or less.

• Ubuntu 18.04
• Ubuntu 19.10
• Apache Traffic Server 8.0.5

In our example, the Apache Traffic Server service will listen on the TCP port 80.

In our example, the Apache service will listen on the TCP port 8080.

Apache Traffic Server - Related Tutorial:

On this page, we offer quick access to a list of tutorials related to the Apache Traffic Server.

Tutorial Apache Traffic Server - Reverse Proxy Installation on Ubuntu Linux

Install the Apache Traffic Server.

Copy to Clipboard

Edit the records.config configuration file.

Copy to Clipboard

Locate the following line.

Copy to Clipboard

Change the service from port 8080 to port 80.

Copy to Clipboard

Restart the Apache traffic server.

Copy to Clipboard

Edit the remap.config configuration file.

Copy to Clipboard

Add the following lines at the end of this configuration file.

Copy to Clipboard

In our example, every connection to the IP address 200.200.200.200 on port 80 will be redirected to the localhost on port 8080.

You need to change the IP address 200.200.200.200 to your server IP address.

Restart the Apache traffic server.

Copy to Clipboard

Verify if the ATS service is listening on the TCP port 80.

Copy to Clipboard

Here is the command output.

Copy to Clipboard

You have finished the Apache traffic service configuration on Ubuntu LInux.

Tutorial Apache Traffic Server - Cache Configuration

The amount of disk space allowed for cache is specified on the configuration file named storage.config.

Edit this configuration file.

Copy to Clipboard

Here is the ATS default disk cache configuration.

Copy to Clipboard

This configuration allows the use of 256MB of disk space for cache.

The ATS cache configuration is set on the configuration file named records.config.

Edit the records.config configuration file.

Copy to Clipboard

Here is the ATS default cache configuration.

Copy to Clipboard

This configuration specifies the following:

• The ATS service will manage automatically the amount of RAM used for cache.
• Objects larger than 4MB will not be kept in the RAM cache.
• The Maximum object size that will be cached is unlimited.

After changing the configuration files, you need to restart the ATS service.

Copy to Clipboard

Congratulations! You are able to change the ATS service cache configuration.

Tutorial - Apache Installation on Ubuntu Linux

Install the Apache service.

Copy to Clipboard

Edit the ports.conf configuration file.

Copy to Clipboard

Here is the ports.conf configuration file, before our configuration.

Copy to Clipboard

Change the Apache default port from 80 to 8080.

Here is the ports.conf configuration file, after our configuration.

Copy to Clipboard

Restart the Apache service.

Copy to Clipboard

Verify if the Apache service is listening on the TCP port 8080.

Copy to Clipboard

Here is the command output.

Copy to Clipboard

You have finished the Apache configuration to use the reverse proxy service.

Tutorial Apache Traffic Server - Testing your installation

After finishing installation, you need to test your configuration.

Open a browser software and enter the external IP address of your Apache traffic server.

In our example, the following URL was entered in the Browser:

• http://200.200.200.200

The ATS service will communicate with the Apache service and answer your request.

haproxy install ubuntu

Use the following command to verify if the ATS service is answering your request.

Copy to Clipboard

Here is the command output.

Copy to Clipboard

As you can see on the header, the Apache traffic server is answering the user request.