How To Install Mtop (MySQL Database Server Monitoring) on CentOS 6

Install Mtop (MySQL Database Server Monitoring) on CentOS 6

In this tutorial, we will show you how to install Mtop (MySQL Database Server Monitoring) on your CentOS 6 server. For those of you who didn’t know, Mtop is an open-source real-time MySQL Server monitoring program that shows queries that are taking a long time to process and kills those longer queries after a certain number of the specified times. Stop program enables us to monitor and identify performance and related issues of MySQL Server from the command line interface similar to Linux Top Command.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple. I will show you through the step-by-step installation Stop on CentOS 6.

Install Mtop (MySQL Database Server Monitoring) on CentOS 6

Step 1. First, let’s start by ensuring your system is up-to-date.

sudo yum update
sudo yum install epel-release

Step 2. Enable the RPMForge repository on your Centos system.

Now enable the RPMForge repository under your Linux machine to download and install the latest version of the MTOP program.

## RHEL/CentOS 6 32-Bit ##

wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.i686.rpm
rpm -Uvh rpmforge-release-0.5.2-2.el6.rf.i686.rpm

## RHEL/CentOS 6 64-Bit ##

wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm
rpm -Uvh rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm

Step 3. Installing Mtop on CentOS 6.

Install Mtop using yumcommand:

sudo yum install mtop

Step 4. Starting Mtop.

To start Mtop program, you need to connect to your MySQL server, using the following command:

# mysql -u root -p

mysql> grant super, reload, process on *.* to mysqltop;
Query OK, 0 rows affected (0.00 sec)

mysql> grant super, reload, process on *.* to [email protected];
Query OK, 0 rows affected (0.00 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

mysql> quit;
Bye

Step 5. Running Mtop in CentOS 6.

mtop

Mtop usage and functions keys:

s – change the number of seconds to delay between updates
m – toggle manual refresh mode on/off
d – filter display with regular expression (user/host/db/command/state/info)
F – fold/unfold column names in select statement display
h – display process for only one host
u – display process for only one user
i – toggle all/non-Sleeping process display
o – reverse the sort order
q – quit
? – hel

Congratulations! You have successfully installed Mtop. Thanks for using this tutorial for installing Mtop (MySQL Database Server Monitoring) on CentOS 6 system. For additional help or useful information, we recommend you to check the official Mtop website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

Save

Save