zabbix

Supported OS Windows Mac OS

통합 버전1.1.1

개요

Zabbix를 연결해 다음을 할 수 있습니다.

  • Datadog Agent를 통해 Zabbix 모니터링
  • Zabbix 알림을 Datadog으로 전송하면 Datadog 이벤트 스트림에서 알림을 이벤트로 확인할 수 있습니다.

설정

Zabbix 점검은 Datadog Agent 패키지에 포함되어 있지 않으므로 설치해야 합니다.

설치

Agent v7.21+/v6.21+의 경우 아래 지침에 따라 호스트에 Zabbix 점검을 설치하세요. Docker Agent 또는 이전 버전의 Agent를 설치하려면 커뮤니티 통합 사용을 참조하세요.

  1. 다음 명령어를 실행해 에이전트 통합을 설치하세요.

    datadog-agent integration install -t datadog-zabbix==<INTEGRATION_VERSION>
    
  2. 통합을 코어 통합과 유사하게 설정하세요.

설정

  1. Zabbix 서버 시간대가 UTC로 설정되어 있는지 확인합니다. Zabbix 표준 시간대에 관한 자세한 내용은 Zabbix 문서에서 확인하세요.

  2. Agent 구성 디렉터리 루트의 conf.d/ 폴더에서 zabbix.d/conf.yaml 파일을 편집해 Zabbix 성능 데이터 수집을 시작하세요. 사용할 수 있는 구성 옵션을 모두 보려면 sample zabbix.d/conf.yaml을 참고하세요.

  3. 에이전트를 다시 시작합니다.

이벤트 수집

Datadog 미디어 유형 생성하기
  1. Administration > Media Types > Create Media Type으로 이동합니다.
  2. Zabbix 템플릿 변수로 webhook에 파라미터를 추가합니다. Datadog api_key와 다음 Zabbix 템플릿 변수를 파라미터로 추가합니다.
파라미터
api_keyYour Datadog API key
event_date{EVENT.DATE}
event_name{EVENT.NAME}
event_nseverity{EVENT.NSEVERITY}
event_tags{EVENT.TAGSJSON}
event_time{EVENT.TIME}
event_value{EVENT.VALUE}
item_name{ITEM.NAME}
alert_message{ALERT.MESSAGE}
alert_subject{ALERT.SUBJECT}
  1. NameDatadog, TypeWebhook으로 설정하고 Script로 다음 코드를 입력합니다.
try {
    Zabbix.Log(4, '[datadog webhook] received value=' + value);

    var params = JSON.parse(value);
    var req = new HttpRequest();
    req.addHeader('Content-Type: application/json');
    var webhook_url = 'https://app.datadoghq.com/intake/webhook/zabbix?api_key=' + params.api_key;
    var webhook_data = value;
    var resp = req.post(webhook_url, webhook_data);
    if (req.getStatus() != 202) {
        throw 'Response code: '+req.getStatus();
    }
    Zabbix.Log(4, '[datadog webhook] received response with status code ' + req.getStatus() + '\n' + resp);
} catch (error) {
    Zabbix.Log(4, '[datadog webhook] event creation failed json : ' + webhook_data)
    Zabbix.Log(4, '[datadog webhook] event creation failed : ' + error);
}
return JSON.stringify({});
  1. “Test” 버튼으로 Webhook이 올바르게 설정되었는지 확인합니다.
기존 사용자에게 Webhook 미디어 할당하기
  1. Webhook 미디어 유형을 구성한 다음, Administration > Users로 이동하여 Webhook을 대표할 전용 Zabbix 사용자를 생성합니다. 예를 들어, Datadog Webhook용 Datadog 별칭을 사용할 수 있습니다. 이 사용자는 Zabbix에 로그인하지 않으므로 미디어를 제외한 모든 설정은 기본값 그대로 둘 수 있습니다.
  2. 사용자 프로필에서 Media 탭으로 이동하여 필수 연락처 정보가 포함된 Webhook을 추가합니다. Webhook이 전송 대상 필드를 사용하지 않는 경우, 지원되는 문자 조합을 입력하여 유효성 검사 조건을 우회할 수 있습니다.
  3. 이 사용자에게 알림을 보내야 하는 모든 호스트에 최소한 읽기 권한을 부여합니다.
Webhook용 알림 작업 구성하기
  1. Configuration > Actions으로 이동합니다.
  2. 페이지 타이틀 드롭다운에서 필수 작업 유형을 선택합니다.
  3. Create Action를 클릭합니다.
  4. 작업의 이름을 지정합니다.
  5. 작업 수행 조건을 선택합니다.
  6. 수행할 작업을 선택합니다.

검증

Agent 상태 하위 명령을 실행하고 점검 섹션에서 zabbix를 찾습니다.

수집한 데이터

메트릭

zabbix.processed.floats_per_sec
(gauge)
Number of processed numeric (float) values per second
Shown as unit
zabbix.processed.per_sec
(gauge)
Number of processed values per second
Shown as unit
zabbix.processed.characters_per_sec
(gauge)
Number of processed character values per second
Shown as unit
zabbix.processed.logs_per_sec
(gauge)
Number of processed log values per second
Shown as unit
zabbix.processed.unsigned_per_sec
(gauge)
Number of processed numeric (unsigned) values per second
Shown as unit
zabbix.processed.text_per_sec
(gauge)
Number of processed text values per second
Shown as unit
zabbix.processed.unsupported_per_sec
(gauge)
Number of processed not supported values per second
Shown as unit
zabbix.process.internal.alerter
(gauge)
Utilization of alerter internal processes, in %
Shown as percent
zabbix.process.internal.config_sync
(gauge)
Utilization of configuration syncer internal processes, in %
Shown as percent
zabbix.process.internal.escalator
(gauge)
Utilization of escalator internal processes, in %
Shown as percent
zabbix.process.internal.history_sync
(gauge)
Utilization of history syncer internal processes, in %
Shown as percent
zabbix.process.internal.housekeeper
(gauge)
Utilization of housekeeper internal processes, in %
Shown as percent
zabbix.process.data_collector.discoverer
(gauge)
Utilization of discoverer data collector processes, in %
Shown as percent
zabbix.process.data_collector.http_poller
(gauge)
Utilization of http poller data collector processes, in %
Shown as percent
zabbix.process.data_collector.icmp_pinger
(gauge)
Utilization of icmp pinger data collector processes, in %
Shown as percent
zabbix.process.data_collector.ipmi_poller
(gauge)
Utilization of ipmi poller data collector processes, in %
Shown as percent
zabbix.process.data_collector.java_poller
(gauge)
Utilization of java poller data collector processes, in %
Shown as percent
zabbix.process.data_collector.poller
(gauge)
Utilization of poller data collector processes, in %
Shown as percent
zabbix.process.data_collector.proxy_poller
(gauge)
Utilization of proxy poller data collector processes, in %
Shown as percent
zabbix.process.internal.self_monitoring
(gauge)
Utilization of self-monitoring internal processes, in %
Shown as percent
zabbix.process.data_collector.snmp_trapper
(gauge)
Utilization of snmp trapper data collector processes, in %
Shown as percent
zabbix.process.internal.timer
(gauge)
Utilization of timer internal processes, in %
Shown as percent
zabbix.process.data_collector.trapper
(gauge)
Utilization of trapper data collector processes, in %
Shown as percent
zabbix.process.data_collector.unreachable_poller
(gauge)
Utilization of unreachable poller data collector processes, in %
Shown as percent
zabbix.queue.duration_10
(gauge)
Zabbix queue over 10 minutes
Shown as unit
zabbix.queue.size
(gauge)
Zabbix queue
Shown as unit
zabbix.cache.config
(gauge)
Zabbix configuration cache, % used
Shown as percent
zabbix.cache.write
(gauge)
Zabbix history write cache, % used
Shown as percent
zabbix.cache.index
(gauge)
Zabbix history index cache, % used
Shown as percent
zabbix.cache.write_trend
(gauge)
Zabbix trend write cache, % used
Shown as percent
zabbix.agent.ping
(gauge)
Zabbix agent ping
Shown as unit
zabbix.process.data_collector.vmware
(gauge)
Utilization of vmware data collector processes, in %
Shown as percent
zabbix.cache.value
(gauge)
Zabbix value cache, % used
Shown as percent
zabbix.cache.value.hits
(gauge)
Zabbix value cache hits
Shown as hit
zabbix.cache.value.misses
(gauge)
Zabbix value cache misses
Shown as miss
zabbix.cache.vmware
(gauge)
Zabbix vmware cache, % used
Shown as percent
zabbix.cache.operating_mode
(gauge)
Zabbix value cache operating mode
Shown as unit
zabbix.process.internal.task_manager
(gauge)
Utilization of task manager internal processes, in %
Shown as percent
zabbix.process.internal.ipmi_manager
(gauge)
Utilization of ipmi manager internal processes, in %
Shown as percent
zabbix.process.internal.alert_manager
(gauge)
Utilization of alert manager internal processes, in %
Shown as percent
zabbix.process.internal.preprocessing_manager
(gauge)
Utilization of preprocessing manager internal processes, in %
Shown as percent
zabbix.process.internal.preprocessing_worker
(gauge)
Utilization of preprocessing worker internal processes, in %
Shown as percent
zabbix.queue.preprocessing
(gauge)
Zabbix preprocessing queue
Shown as unit
zabbix.queue.lld
(gauge)
Zabbix LLD queue
Shown as unit
zabbix.process.internal.lld_manager
(gauge)
Utilization of LLD manager internal processes, in %
Shown as unit
zabbix.process.internal.lld_worker
(gauge)
Utilization of LLD worker internal processes, in %
Shown as percent
zabbix.cpu.count
(gauge)
Number of CPUs
Shown as unit
zabbix.cpu.iowait_time
(gauge)
CPU iowait time
zabbix.context_switches_per_sec
(gauge)
Context switches per second
zabbix.cpu.guest_nice_time
(gauge)
CPU guest nice time
zabbix.cpu.guest_time
(gauge)
CPU guest time
zabbix.cpu.softirq_time
(gauge)
CPU softirq time
zabbix.cpu.interrupt_time
(gauge)
CPU interrupt time
zabbix.cpu.steal_time
(gauge)
CPU steal time
zabbix.cpu.nice_time
(gauge)
CPU nice time
zabbix.load.avg.1_min
(gauge)
Load average (1m avg)
zabbix.cpu.user_time
(gauge)
CPU user time
zabbix.cpu.system_time
(gauge)
CPU system time
zabbix.cpu.idle_time
(gauge)
CPU idle time
zabbix.load.avg.15_min
(gauge)
Load average (15m avg)
zabbix.load.avg.5_min
(gauge)
Load average (5m avg)
zabbix.interrupts_per_sec
(gauge)
Interrupts per second
zabbix.memory.avail_percent
(gauge)
Available memory in %
zabbix.memory.total
(gauge)
Total memory
zabbix.memory.avail
(gauge)
Available memory
zabbix.swap_space.total
(gauge)
Total swap space
zabbix.swap_space.free
(gauge)
Free swap space
zabbix.swap_space.free_percent
(gauge)
Free swap space in %
zabbix.system.uptime
(gauge)
System uptime
zabbix.system.boot_time
(gauge)
System boot time
zabbix.system.local_time
(gauge)
System local time
zabbix.user.logged_in
(gauge)
Number of logged in users
zabbix.open_fd.max
(gauge)
Maximum number of open file descriptors
zabbix.processes_max
(gauge)
Maximum number of processes
zabbix.processes_count
(gauge)
Number of processes
zabbix.processes_running_count
(gauge)
Number of running processes
zabbix.cpu.used
(gauge)
CPU utilization
zabbix.agent.avail
(gauge)
Zabbix agent availability
zabbix.process.internal.alert_sync
(gauge)
Utilization of alert syncer internal processes, in %
Shown as percent
zabbix.memory.used
(gauge)
Memory utilization

이벤트

Zabbix 알림은 Datadog 이벤트 스트림에서 이벤트로 수집됩니다.

서비스 점검

zabbix.can_connect

Returns CRITICAL if the Agent can’t connect to the Zabbix API, OK otherwise

Statuses: ok, critical

트러블슈팅

도움이 필요하신가요? Datadog 고객 지원팀에 문의하세요.