Available solutions
GCP Compute Engine Instance by HTTP
Overview
This template is designed to monitor Google Cloud Platform Compute Engine instances by Zabbix.
Requirements
Zabbix version: 7.4 and higher.
Tested versions
This template has been tested on:
- GCP Compute Engine
Configuration
Zabbix should be configured according to the instructions in the Templates out of the box section.
Setup
This template will be automatically connected to discovered entities with all their required parameters pre-defined.
Macros used
| Name | Description | Default |
|---|---|---|
| {$GCP.DATA.TIMEOUT} | A response timeout for an API. |
15s |
| {$GCP.TIME.WINDOW} | Time interval for the data requests. Supported usage type: 1. The default update interval for most of the items. 2. The minimal time window for the data requested in the Monitoring Query Language REST API request. |
5m |
| {$GCP.PROXY} | Sets HTTP proxy value. If this macro is empty then no proxy is used. |
|
| {$HTTP.TLS.VERIFY} | TLS certificate verification for script items: "none" - disabled, "peer" - verify the certificate chain and expiration, "full" - full verification. Any other value enables full verification. To override the setting for this template only, define the macro with the context "GCP Compute Engine Instance", e.g. {$HTTP.TLS.VERIFY:"GCP Compute Engine Instance"}. |
full |
| {$GCE.DISK.NAME.MATCHES} | The filter to include GCP Compute Engine disks by namespace. |
.* |
| {$GCE.DISK.NAME.NOT_MATCHES} | The filter to exclude GCP Compute Engine disks by namespace. |
CHANGE_IF_NEEDED |
| {$GCE.DISK.DEV_TYPE.MATCHES} | The filter to include GCP Compute Engine disks by device type. |
.* |
| {$GCE.DISK.DEV_TYPE.NOT_MATCHES} | The filter to exclude GCP Compute Engine disks by device type. |
CHANGE_IF_NEEDED |
| {$GCE.DISK.STOR_TYPE.MATCHES} | The filter to include GCP Compute Engine disks by storage type. |
.* |
| {$GCE.DISK.STOR_TYPE.NOT_MATCHES} | The filter to exclude GCP Compute Engine disks by storage type. |
CHANGE_IF_NEEDED |
| {$GCE.CPU.UTIL.MAX} | GCP Compute Engine instance CPU utilization threshold. |
95 |
| {$GCE.RAM.UTIL.MAX} | GCP Compute Engine instance RAM utilization threshold. |
90 |
Items
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| Metrics get | GCP Compute Engine metrics get in raw format. |
Script | gcp.gce.metrics.get Preprocessing
|
| Firewall: Dropped packets | Count of incoming packets dropped by the firewall. |
Dependent item | gcp.gce.firewall.dropped_packets_count Preprocessing
|
| Firewall: Dropped bytes | Count of incoming bytes dropped by the firewall. |
Dependent item | gcp.gce.firewall.dropped_bytes_count Preprocessing
|
| Guest visible vCPUs | Number of vCPUs visible inside the guest. For many GCE machine types, the number of vCPUs visible inside the guest is equal to the For shared-core machine types, the number of guest-visible vCPUs differs from the number of reserved cores. For example, e2-small instances have two vCPUs visible inside the guest and 0.5 fractional vCPUs reserved. Therefore, for an e2-small instance, |
Dependent item | gcp.gce.cpu.guest_visible_vcpus Preprocessing
|
| Reserved vCPUs | Number of vCPUs reserved on the host of the instance. |
Dependent item | gcp.gce.cpu.reserved_cores Preprocessing
|
| Scheduler wait time | Wait time is the time a vCPU is ready to run, but unexpectedly not scheduled to run. The wait time returned here is the accumulated value for all vCPUs. The time interval for which the value was measured is returned by Monitoring in whole seconds as start_time and end_time. This metric is only available for VMs that belong to the e2 family or to overcommitted VMs on sole-tenant nodes. |
Dependent item | gcp.gce.cpu.scheduler_wait_time Preprocessing
|
| CPU usage time | Delta vCPU usage for all vCPUs, in vCPU-seconds. To compute the per-vCPU utilization fraction, divide this value by (end-start)*N, where end and start define this value's time interval and N is This value is reported by the hypervisor for the VM and can differ from |
Dependent item | gcp.gce.cpu.usage_time Preprocessing
|
| CPU utilization | Fractional utilization of allocated CPU on this instance. This metric is reported by the hypervisor for the VM and can differ from |
Dependent item | gcp.gce.cpu.utilization Preprocessing
|
| Memory size | Total VM memory size. This metric is only available for VMs that belong to the e2 family; returns empty value for different instance types. |
Dependent item | gcp.gce.memory.ram_size Preprocessing
|
| Memory used | Memory currently used in the VM. This metric is only available for VMs that belong to the e2 family; returns empty value for different instance types. |
Dependent item | gcp.gce.memory.ram_used Preprocessing
|
| Memory usage percentage | Memory usage Percentage. This metric is only available for VMs that belong to the e2 family; returns empty value for different instance types. |
Dependent item | gcp.gce.memory.ram_pused Preprocessing
|
| VM swap in | The amount of memory read into the guest from its own swap space. This metric is only available for VMs that belong to the e2 family; returns empty value for different instance types. |
Dependent item | gcp.gce.memory.swap_in_bytes_count Preprocessing
|
| VM swap out | The amount of memory written from the guest to its own swap space. This metric is only available for VMs that belong to the e2 family; returns empty value for different instance types. |
Dependent item | gcp.gce.memory.swap_out_bytes_count Preprocessing
|
| Network: Received bytes | Count of bytes received from the network without load-balancing. |
Dependent item | gcp.gce.network.lb.received_bytes_count.false Preprocessing
|
| Network: Received bytes: Load-balanced | Whether traffic was received by an L3 loadbalanced IP address assigned to the VM. Traffic that is externally routed to the VM's standard internal or external IP address, such as L7 loadbalanced traffic, is not considered to be loadbalanced in this metric. The value is empty when load-balancing is not used. |
Dependent item | gcp.gce.network.lb.received_bytes_count.true Preprocessing
|
| Network: Received packets | Count of packets received from the network without load-balancing. |
Dependent item | gcp.gce.network.lb.received_packets_count.false Preprocessing
|
| Network: Received packets: Load-balanced | Whether traffic was received by an L3 loadbalanced IP address assigned to the VM. Traffic that is externally routed to the VM's standard internal or external IP address, such as L7 loadbalanced traffic, is not considered to be loadbalanced in this metric. The value is empty when load-balancing is not used. |
Dependent item | gcp.gce.network.lb.received_packets_count.true Preprocessing
|
| Network: Sent bytes | Count of bytes sent over the network without load-balancing. |
Dependent item | gcp.gce.network.lb.sent_bytes_count.false Preprocessing
|
| Network: Sent bytes: Load-balanced | Whether traffic was received by an L3 loadbalanced IP address assigned to the VM. Traffic that is externally routed to the VM's standard internal or external IP address, such as L7 loadbalanced traffic, is not considered to be loadbalanced in this metric. The value is empty when load-balancing is not used. |
Dependent item | gcp.gce.network.lb.sent_bytes_count.true Preprocessing
|
| Network: Sent packets | Count of packets sent over the network without load-balancing. |
Dependent item | gcp.gce.network.lb.sent_packets_count.false Preprocessing
|
| Network: Sent packets: Load-balanced | Whether traffic was received by an L3 loadbalanced IP address assigned to the VM. Traffic that is externally routed to the VM's standard internal or external IP address, such as L7 loadbalanced traffic, is not considered to be loadbalanced in this metric. The value is empty when load-balancing is not used. |
Dependent item | gcp.gce.network.lb.sent_packets_count.true Preprocessing
|
| Network: Mirrored bytes | The count of mirrored bytes. |
Dependent item | gcp.gce.network.mirrored_bytes_count Preprocessing
|
| Network: Mirrored packets | The count of mirrored packets. |
Dependent item | gcp.gce.network.mirrored_packets_count Preprocessing
|
| Network: Mirrored packets dropped: Out of quota | The count of mirrored packets dropped. Reason - out of quota. |
Dependent item | gcp.gce.network.mirr_dropped_packets.out_of_quota Preprocessing
|
| Network: Mirrored packets dropped: Unknown | The count of mirrored packets dropped. Reason - unknown. |
Dependent item | gcp.gce.network.mirr_dropped_packets.unknown Preprocessing
|
| Network: Mirrored packets dropped: Invalid | The count of mirrored packets dropped. Reason - invalid. |
Dependent item | gcp.gce.network.mirr_dropped_packets.invalid Preprocessing
|
| Integrity: Early boot validation status | The validation status of early boot integrity policy. Empty value if integrity monitoring isn't enabled. |
Dependent item | gcp.gce.integrity.early_boot_validation_status Preprocessing
|
| Integrity: Late boot validation status | The validation status of late boot integrity policy. Empty value if integrity monitoring isn't enabled. |
Dependent item | gcp.gce.integrity.late_boot_validation_status Preprocessing
|
| Instance uptime | Elapsed time since the VM was started, in seconds. |
Dependent item | gcp.gce.instance.uptime Preprocessing
|
| Instance state | GCP Compute Engine instance state. |
HTTP agent | gcp.gce.instance.state Preprocessing
|
| Disks get | Disk entities and metrics related to a particular instance. |
Script | gcp.gce.disks.get Preprocessing
|
Triggers
| Name | Description | Expression | Severity | Dependencies and additional info |
|---|---|---|---|---|
| GCP Compute Engine Instance: High CPU utilization | The CPU utilization is too high. The system might be slow to respond. |
min(/GCP Compute Engine Instance by HTTP/gcp.gce.cpu.utilization,15m) >= {$GCE.CPU.UTIL.MAX} |
Average | Manual close: Yes |
| GCP Compute Engine Instance: High memory utilization | RAM utilization is too high. The system might be slow to respond. |
min(/GCP Compute Engine Instance by HTTP/gcp.gce.memory.ram_pused,15m) >= {$GCE.RAM.UTIL.MAX} |
Average | |
| GCP Compute Engine Instance: Instance is in suspended state | The VM is in a suspended state. You can resume the VM or delete it. |
last(/GCP Compute Engine Instance by HTTP/gcp.gce.instance.state) = 7 |
Info | Manual close: Yes |
| GCP Compute Engine Instance: The instance is in repairing state | The VM is being repaired. |
last(/GCP Compute Engine Instance by HTTP/gcp.gce.instance.state) = 4 |
Warning | Manual close: Yes |
| GCP Compute Engine Instance: The instance is in terminated state | The VM is stopped. You stopped the VM, or the VM encountered a failure. |
last(/GCP Compute Engine Instance by HTTP/gcp.gce.instance.state) = 5 |
Average | Manual close: Yes |
| GCP Compute Engine Instance: Failed to get the instance state | Failed to get the instance state. |
last(/GCP Compute Engine Instance by HTTP/gcp.gce.instance.state) = 10 |
Average | Manual close: Yes |
LLD rule GCP Compute Engine: Physical disks discovery
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| GCP Compute Engine: Physical disks discovery | GCP Compute Engine: Physical disks discovery. |
Dependent item | gcp.gce.phys.disks.discovery Preprocessing
|
Item prototypes for GCP Compute Engine: Physical disks discovery
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| Disk [{#GCE.DISK.NAME}]: Raw data | Data in raw format for the disk with the name [{#GCE.DISK.NAME}]. |
Dependent item | gcp.gce.quota.single.raw[{#GCE.DISK.NAME}] Preprocessing
|
| Disk [{#GCE.DISK.NAME}]: Read bytes | Count of bytes read from [{#GCE.DISK.NAME}] disk. |
Dependent item | gcp.gce.disk.read_bytes_count[{#GCE.DISK.NAME}] Preprocessing
|
| Disk [{#GCE.DISK.NAME}]: Read operations | Count of read IO operations from [{#GCE.DISK.NAME}] disk. |
Dependent item | gcp.gce.disk.read_ops_count[{#GCE.DISK.NAME}] Preprocessing
|
| Disk [{#GCE.DISK.NAME}]: Write bytes | Count of bytes written to {#GCE.DISK.NAME}] disk. |
Dependent item | gcp.gce.disk.write_bytes_count[{#GCE.DISK.NAME}] Preprocessing
|
| Disk [{#GCE.DISK.NAME}]: Write operations | Count of write IO operations to [{#GCE.DISK.NAME}] disk. |
Dependent item | gcp.gce.disk.write_ops_count[{#GCE.DISK.NAME}] Preprocessing
|