【问题标题】:zabbix agent return powershell valuezabbix 代理返回 powershell 值
【发布时间】:2019-04-08 14:46:13
【问题描述】:

我尝试使用 zabbix 代理监控 cpu 服务器,zabbix 不支持我的项目密钥,我尝试了这个项目密钥:

#system.run["powershell.exe -NoProfile -ExecutionPolicy ByPass -File C:\zabbix\conf\CPU_%.ps1"] 

#system.run["C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File C:\zabbix\conf\CPU_%.ps1",]

我想知道zabbix支持哪个item key?

感谢您的回复

【问题讨论】:

  • 为什么不简单地使用 percounter? "perf_counter[\Processor(_Total)\% User Time] perf_counter[\Processor(_Total)\% Privileged Time] perf_counter[\System\Processor Queue Length] perf_counter[\Paging File(_Total)\% Usage]"
  • 您是否在代理上设置了EnableRemoteCommands=1?默认情况下禁用此功能,但 system.run 键需要它才能工作。另外:日志在说什么?

标签: powershell zabbix


【解决方案1】:

在 zabbix_agentd.conf 或 zabbix_agent2.conf 中添加该行:

UserParameter=CPU[*], powershell -File "C:\zabbix\conf\CPU_%.ps1"

添加元素 Zabbix Agent (Active) with key CPU[]

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-12-17
    • 2013-01-21
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多