【问题标题】:Zabbix on docker-compose don't start zabbix-agentdocker-compose 上的 Zabbix 不启动 zabbix-agent
【发布时间】:2021-08-23 19:50:40
【问题描述】:

我过去使用过基于 docker-compose 的 zabbix 4.x 版。

当我启动环境时,我可以数出超过 5 个容器,包括 zabbix-agent。

我现在正在尝试启动版本 5.0、5.2 和 5.4,但我总是会遇到这种情况

  1. 开始的容器只有 3 个(比指示的少得多 在 yaml 文件中)
  2. 带有 zabbix 代理的容器没有运行和监听。

关于 docker-compose up 我有这个错误

WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
WARNING: The following deploy sub-keys are not supported and have been ignored: resources.reservations.cpus
....
 Zabbix agent item "system.cpu.intr" on host "Zabbix server" failed: first network error, wait for 15 seconds
 Zabbix agent item "vm.memory.size[pavailable]" on host "Zabbix server" failed: another network error, wait for 15 seconds

此外,我必须对某些服务器使用主动检查,因为虚拟机位于 NAT 后面,服务器无法访问:在文档中,我看到在 Web 界面中您可以选择主动代理或被动代理,但是在我的服务器上,我只有语音“代理”,没有被动或主动。

For the Zabbix agent, there is a choice between ‘Zabbix agent (passive)’ and ‘Zabbix agent (active)’.

我在 centos 7,Docker 版本 1.13.1,构建 7d71120/1.13.1,docker-compose 版本 1.29.2,构建 5becea4c

【问题讨论】:

  • 您是使用官方 docker-compose yamls(如果有的话)还是自己编写的?

标签: docker-compose zabbix agent


【解决方案1】:

我不知道你是否还有这个问题,但解决方案是使用“all”配置文件运行 docker compose:

docker-compose --profile all up

从 docker-compose 1.28.0 开始,您可以选择从 docker 文件运行一些服务。您可以运行多个配置文件,因此在新的 zabbix compose 文件中有一个配置文件称为“完整”和“全部”。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2021-06-02
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-02-16
    • 1970-01-01
    相关资源
    最近更新 更多