linux下配置免安装版zabbix-agent配置详解

2021/4/11 7:25:45

本文主要是介绍linux下配置免安装版zabbix-agent配置详解,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

Linux 下zabbix-agent免安装版配置

  1. 检查服务器端zabbix-server的版本
    [root@zabbix ~]# zabbix_server -V
    linux下配置免安装版zabbix-agent配置详解

  2. 下载对应版本的zabbix-agent版本
    检查客户端系统的内核版本:
    [root@test-server src]# uname -a
    linux下配置免安装版zabbix-agent配置详解

登录官网,选择对应版本的zabbix-agent版本
https://www.zabbix.com/download_agents?version=5.0+LTS&release=5.0.0&os=Linux&os_version=3.0&hardware=i386&encryption=No+encryption&packaging=Archive

linux下配置免安装版zabbix-agent配置详解

linux下配置免安装版zabbix-agent配置详解

[root@test-server src]# wget https://cdn.zabbix.com/zabbix/binaries/stable/5.0/5.0.10/zabbix_agent-5.0.10-linux-3.0-i386-static.tar.gz

linux下配置免安装版zabbix-agent配置详解

解压缩后,看到有三个文件夹:
[root@test-server src]# tar -xvf zabbix_agent-5.0.10-linux-3.0-i386-static.tar.gz -C zabbix_agent/

linux下配置免安装版zabbix-agent配置详解

[root@test-server src]# mv zabbix_agent /usr/local/
[root@test-server src]# cd /usr/local/zabbix_agent/conf/

linux下配置免安装版zabbix-agent配置详解

[root@test-server conf]# vi zabbix_agentd.conf
[root@test-server conf]# egrep -v "#|^$" zabbix_agentd.conf

linux下配置免安装版zabbix-agent配置详解

  1. 建立zabbix用户
    [root@test-server conf]# useradd zabbix -s /bin/false

linux下配置免安装版zabbix-agent配置详解

  1. 建立systemctl 启动文件
    [root@test-server system]# vi /usr/lib/systemd/system/zabbix-agent.service

linux下配置免安装版zabbix-agent配置详解

[root@test-server system]# systemctl daemon-reload
[root@test-server conf]# systemctl start zabbix-agent.service

linux下配置免安装版zabbix-agent配置详解

检查启动的服务:
[root@test-server ~]# netstat -nutpl |grep zabbix
linux下配置免安装版zabbix-agent配置详解

设置为开机自启动:
[root@test-server ~]# systemctl enable zabbix-agent

linux下配置免安装版zabbix-agent配置详解

  1. 配置防火墙
    配置防火墙放通10050端口:
    [root@test-server ~]# firewall-cmd --zone=public --add-port=10050/tcp --permanent

    [root@test-server ~]# firewall-cmd --reload

    [root@test-server ~]# firewall-cmd --list-ports

linux下配置免安装版zabbix-agent配置详解

  1. 配置监控主机:
    登录zabbix 的web界面,点击 配置 – 主机 – 新建主机:

linux下配置免安装版zabbix-agent配置详解

linux下配置免安装版zabbix-agent配置详解

连接模板:
linux下配置免安装版zabbix-agent配置详解

配置好后,稍等会儿刷新就能看到已连接成功:
linux下配置免安装版zabbix-agent配置详解

Zabbix5.0企业级分布式监控系统:精讲与企业应用

linux下配置免安装版zabbix-agent配置详解



这篇关于linux下配置免安装版zabbix-agent配置详解的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程