Monitoring of Memcached

04 / May / 2015 by Rajdeep Singh 0 comments

Memcached is an ideal platform for accelerating application performance. It is important to identify and resolve the problem before it impact business. phpMemcachedAdmin is a great tool to proactively monitor the health and performance of Memcached. It will give you clear picture of hit and miss ratio and as well eviction rate in real time. It also support command execution and dumping keys value.

Configuration Steps:-

1. PhpMemcachedAdmin Installation.
2. Nginx configuration.
3. Check Cache Stats.

1. PhpMemcachedAdmin Installation:-

cd /var/www/html/admin/
tar xvf phpMemcachedAdmin*
chmod 0777 Config/Memcache.php
chmod 0777 Temp/

To edit configuration file run below command:-

sed -i s/<Memcahce End Point>/g Config/Memcache.php


2. Nginx configuration:-
In Nginx set credentials, allow access from your IP. So, it can be accessible only from your premises.

vi /etc/nginx/sites-enabled/default
location /admin/ {
auth_basic "Restricted";
auth_basic_user_file /etc/nginx/.htpasswd/passwd;
allow x.x.x.x; #enter your ip here
deny all;

With help of htpasswd command set username and password and then restart service:-

mkdir /etc/nginx/.htpasswd/
htpasswd -c /etc/nginx/.htpasswd/passwd admin
service nginx restart


3. Check Cache Stats:-
We have done with configuration steps and to access front end type your server IP in the browser.

I hope it would help you to monitor the availability and statistics of Memcached.


Leave a Reply

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