Hello, hello, friends, this is Changqing~
Everyone should have this problem after installing zabbix, that is, the ZBX font is red
Then display an error
get value from agent failed: cannot connect to [[127.0.0.1]:10050]
This probably means that the agent connection failed.
Solution
- Let's first look at the firewall status
[root@m01 ~]# getenforce #显示当前SELinux的应用模式
Disabled
[root@m01 ~]# systemctl status firewalld #查看防火墙状态
● firewalld.service - firewalld - dynamic firewall daemon
Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
Active: inactive (dead)
Docs: man:firewalld(1)
2. Check whether the agent is started, check port 10050
netstat -lntup|grep 10050
It can be seen that there is no port 10050, indicating that the agent is not started, so we need to start the agent
[root@m01 ~]# systemctl start zabbix-agent.service #启动agent服务
[root@m01 ~]# systemctl status zabbix-agent.service #查看状态
● zabbix-agent.service - Zabbix Agent
Loaded: loaded (/usr/lib/systemd/system/zabbix-agent.service; disabled; vendor preset: disabled)
Active: active (running) since Mon 2022-07-04 11:49:31 CST; 7s ago