Rootop 服务器运维与web架构

Zabbix 服务器没有运行,显示信息也许不是当前

| 暂无评论

有的时候是因为selinux没有关,还有的情况需要查看zabbix server日志。
1、关selinux
setenforce 0 (或者改配置文件永久关掉selinux)

2、查看日志
[root@localhost mysql]# cat /usr/local/zabbix/etc/zabbix_server.conf | grep LogFile
# file – file specified with LogFile parameter
### Option: LogFile
# LogFile=
LogFile=/tmp/zabbix_server.log

去查 /tmp/zabbix_server.log 文件

7189:20180316:102014.462 database is down: reconnecting in 10 seconds
7189:20180316:102024.462 [Z3001] connection to database ‘zabbix’ failed: [2002] Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2)

可以看到是没有找到mysql.sock文件,我mysql的sock文件在/tmp下,直接软链接一个到日志里的路径即可。

原创文章,转载请注明。本文链接地址: https://www.rootop.org/pages/1877.html

作者:Venus

服务器运维与性能优化

发表回复