CENTOS7 's Zabbix monitoring MySQL (mariadb) database

Source: Internet
Author: User

First, Zabbix3.2.6 use the self-brought template to monitor MySQL

Add Zabbix_agent Client Method: http://www.cnblogs.com/lei0213/p/8858269.html

MySQL server-side configuration

1, need to know:

1, if you want to monitor MySQL or mariadb database, first you have to ensure that the normal operation of the server, so the first need to monitor this Linux server, if you add Linux monitoring, you can view my previous blog post.

2, the database needs authorization.

Mysql>grant USAGE on *. * to ' Zabbix ' @ ' localhost ' identified by ' Zabbix ';

3, configuration userparameter_mysql.conf (here need to download Zabbix client installation package, in fact, the server installation can be)

CD ZABBIX-3.2.6/CONF/ZABBIX_AGENTD/CP userparameter_mysql.conf/etc/zabbix/zabbix_agentd.conf.d/

4. Add the configuration file my.cnf that is used to correlate MySQL, and modify the MySQL path in the template configuration file

Cd/etc/zabbix/vim. my.cnf

5. mysql configuration file my.cnf Add or change the following password

#user =zabbix Authorized User

#password =zabbix Authorized User Password

#soket =soket storage location, absolute path

[mysql]host=localhostuser=zabbixpassword=zabbixsocket=/var/lib/mysql/mysql.sock[mysqladmin]host=localhostuser= Zabbixpassword=zabbixsocket=/var/lib/mysql/mysql.sock

When you are finished, restart the MySQL database server to see if it works.

4, modify the userparameter_mysql.conf

  Change/var/lib/zabbix in/etc/zabbix/zabbix_agentd.conf.d/userparameter_mysql.conf configuration file to/etc/zabbix

Sed-i ' [email protected]/var/lib/[email protected]/etc/[email protected] '/etc/zabbix/zabbix_agentd.conf.d/ Userparameter_mysql.conf

5, modify the zabbix_agentd.conf file, add the following line

Include=/etc/zabbix/zabbix_agentd.conf.d/*.conf

6, restart MySQL, agentd service

Zabix-server-side configuration

Note that I am here to monitor the proxy way

1. Create a MySQL monitoring group

  

2. Add Monitoring Host

3. Adding monitoring templates

4. View

Reference to: http://blog.51cto.com/wzlinux/1944741

CENTOS7 's Zabbix monitoring MySQL (mariadb) database

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.