How to monitor your Apache web server logs with

Jack Wallen shows you how to install Apache Realtime Log Monitor,, on Ubuntu Server 16.04, and why it is a must have for any web server administrator.

As a web server administrator, one of your most important tasks is to be able to easily monitor the logs in real time. Having this ability can mean the difference between knowing what is going right and wrong with your web servers and how to fix problems quickly. But for some administrators, having to SSH into a server and then view various log files, through the terminal window, can be a frustrating exercise. Fortunately, there are plenty of tools out there that allow you to make this a lot easier. One of these tools is allows you to monitor log files in real time, for your Apache web server, with the convenience of a web browser. I want to show you how to install this incredibly useful tool on an Ubuntu LAMP (Linux Apache MySQL PHP) server.

What you will need

I’m assuming your LAMP server is already up and running. You will also need to access an account with sudo rights. With all of that in place, it’s time to install.


The installation of is handled entirely through the command line. The first thing to do is update / upgrade. Keep in mind that if the upgrade includes the kernel, you will need to restart your system. So it’s always best to upgrade during off-peak hours. The update / upgrade is handled with the following two commands:

sudo apt update
sudo apt upgrade

Once these are done and the server does not require a restart, you are good to go.

The first thing to do is to install both node.js and NPM. These can be installed with a single command:

sudo apt install nodejs npm

Enter your sudo password and validate the installation. Once this installation is complete, you are ready to continue.

We will display on http (not https). For this reason, we have to silence an SSL certificate error with the command:

sudo npm config set strict-ssl false

Now we install with the command:

sudo npm install -g --user "root"


The installation will create a new directory in / root, called To access this directory, you must first run the command sudo -s. Once you have successfully authenticated with your sudo password, navigate to the new directory with the command:

cd /root/

There are three files in this directory:

  • harvester.conf
  • log_server.conf
  • web_server.conf

Open Harvester.conf with the nano Harvester.conf command and make sure the nodeName line is:

nodeName: "Webserver",

Save and close this file. Open web_server.conf. In that file you will see this section:

  restrictHTTP: [

If you want to restrict to specific IP addresses, do so here. Save and close this file.

It’s time to start the services. This is done with the following two commands: & &

Viewing logs

On a desktop computer that has access to the IP address of your web server, point your default web browser to http: // SERVER_IP: 28778 (where SERVER_IP is the IP address of the server). You should see the main page (Figure A), already spitting out real-time log entries for your Apache web server. If you don’t see anything, be sure to select both Apache and Webserver in the left navigation (click on one and both will be automatically selected).

Figure A

Figure A

If the entries become too difficult to display, you can always place your cursor in the upper right corner of the window to display the search bar (Number B).

Number B

Number B

Filtering your logs makes them easier to view.

Welcome to easy, real-time Apache logs

Every Apache web administrator should consider a must have, especially if you don’t want to have to browse text files in a terminal window. For easy, real-time Apache logs, you don’t need to look any further than Try and see if it does not terminate your default Apache web server log monitor.

Also look

Source link

Comments are closed.