Comments (3)
Ha you just hit something which I forgot to document :/
Service MySQL template has macro:
{$MYSQL_CMD} => HOME=/var/lib/zabbix /usr/bin/mysql --login-path=monitoring -Nse
You need to create /var/lib/zabbix directory and using mysql_config_editor program store in it .mylogin.cnf file with details about username, password and address of the mysql server.
Just use command like below:
[root@domek ~]# HOME=/var/lib/zabbix mysql_config_editor set --user=monitoring --host=localhost --password
Enter password:
[root@domek ~]# HOME=/var/lib/zabbix mysql_config_editor print
[client]
user = monitoring
password = *****
host = localhost
Than you need to change ownership of the /var/lib/zabbix
[root@domek ~]# chown -R zabbix:zabbix /var/lib/zabbix; chmod 700 /var/lib/zabbix; chmod 600 /var/lib/zabbix/.*
FYI I've started writing my own agent loadable module to provide template template items abstractions but this module is not finished yet. https://github.com/kloczek/zbx_mod_mysql
Whit this module will be not necessary to use external commands.
from zabbix-templates.
@kloczek after I do those steps I lost connection to my DB on zabbix, and coudn't open zabbix's website:
Error connecting to database: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111).
Any idea why this happened? And how can I avoid it?
from zabbix-templates.
First: are you able to connect to the mysql database using mysql client command?
I suppose that you not been able to do that :)
from zabbix-templates.
Related Issues (8)
- Error when try to import OS Windows template HOT 14
- Add a trigger for the Processor Times graph (at 80-85% level)? HOT 1
- Disk IO(Bps to ms + 2 triggers)
- Add graph(s) that represent currents transfer speeds for all available network interface(cards). HOT 1
- documentation on how to configure mysql template HOT 3
- Error in import HOT 2
- Announcement: development cycle comments HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zabbix-templates.