Monitor apache webserver realtime using Apachetop

Apachetop is a monitoring tool to monitor  the  performance of apache server and to watch request which are being served live. It’s very likely based on application mytop. It displays current number of reads, writes,  number of requests processed so far and current request being processed. This tool will use apache access_log to  Monitor apache webserver realtime using apachetop

Install apachetop

If you are using CentOS you can install this application by using yum as follows

$ yum install apachetop

On Debian based systems you can install using apt-get as follows,

$ apt-get install apachetop

If you wanna install it from source, download/clone it from github and then compile/install.

Clone Repository

$ git clone

How to apachetop

Run the application to monitor apache webserver, to do so, type apachetop command. You would see the screen something like below

last hit: 23:26:57         atop runtime:  0 days, 00:00:25             23:26:59
All:           46 reqs (   2.7/sec)       1407.2K (   82.8K/sec)      30.6K/req
2xx:	  46 ( 100%) 3xx:	0 ( 0.0%) 4xx:     0 ( 0.0%) 5xx:     0 ( 0.0%)
R ( 25s):      46 reqs (   1.8/sec)       1407.2K (   56.3K/sec)      30.6K/req
2xx:	  46 ( 100%) 3xx:	0 ( 0.0%) 4xx:     0 ( 0.0%) 5xx:     0 ( 0.0%)

    2  0.12   0.2  0.0 /image/log.png
    1  0.06  45.3  2.8 /includes/css/dashicons.min.css
    1  0.06  19.5  1.2 /includes/css/bar.min.css

If you open apachetop. You can see the help by hitting letter h.

ApacheTop version 0.15.6, Copyright (c) 2003-2004, Chris Elsworth

d : switch item display between urls/referrers/hosts
n : switch numbers display between hits & bytes or return codes
h or ? : this help window
p : (un)pause display (freeze updates)
q : quit ApacheTop
up/down : move marker asterisk up/down
right/left : enter/exit detailed subdisplay mode

s: SORT BY: [the appropriate menu will appear for your display]
r) requests R) reqs/sec b) bytes B) bytes/sec
2) 2xx 3) 3xx 4) 4xx 5) 5xx

u) urls r) referrers h) hosts

a) add/edit menu c) clear all s) show active (not done yet)
u) to urls r) to referrers h) to hosts

You can filter request by URL or referrers or hosts. You can toggle filter by using f when apachetop is running


This application by default assumes that the path of access_log file as /var/log/httpd/access_log. If you have a custom installation of apache or running apache on SCL (Software Collections).You can specify the path with option -f. i.e,

$apachetop -f /opt/rh/httpd24/root/etc/httpd/logs/access_log


Leave a Reply

Your email address will not be published. Required fields are marked *