Prepare and test your skills

Prepare and test your skills

Free sample question with answers and detailed explanation below. The Associate Cloud Engineer practice bank has an additional 2,014 practice questions.Try 10 free realistic questions: instant score, no credit card, and no account required.
An administrator manages several Linux Compute Engine instances running latency-sensitive workloads. The Google Cloud Ops Agent is installed across all instances and collects host system metrics (such as CPU, disk, and memory) at the default interval of 60 seconds. To support granular performance troubleshooting, the administrator needs to increase the sampling rate so that host metrics are collected every 30 seconds.
What should the administrator do to implement this change?
The Google Cloud Ops Agent manages telemetry collection on Compute Engine instances by combining Fluent Bit for logs and the OpenTelemetry Collector for metrics. Its configuration architecture relies on a built-in baseline merged with user-defined overrides. User overrides for Linux systems are placed in /etc/google-cloud-ops-agent/config.yaml. The agent configuration consists of three primary components: receivers (defining what telemetry to gather and at what interval), processors (defining how telemetry is modified or filtered), and service pipelines (connecting receivers and processors into active data flows).

To reduce the host metric collection interval from 60 seconds to 30 seconds:
hostmetrics receiver under metrics.receivers.hostmetrics under metrics.receivers in /etc/google-cloud-ops-agent/config.yaml with collection_interval: 30s, the user configuration overrides the built-in 60-second default setting.sudo systemctl restart google-cloud-ops-agent applies the new collection rate immediately.hostmetrics) replaces only the specified attributes while preserving the rest of the built-in pipeline structure.collection_interval) according to specific workload and performance troubleshooting needs./etc/google-cloud-ops-agent/config.yaml rather than modifying internal package files.Modifying /etc/google-cloud-ops-agent/config.yaml is the standard method for customizing the Ops Agent. It precisely targets the hostmetrics receiver where sampling frequency is configured, preserves all other default monitoring pipelines, and safely applies changes with minimal operational effort.
The Google Cloud Ops Agent includes a built-in configuration that defines default behavior, including collecting standard system logs (/var/log/messages, /var/log/syslog, or Windows Event Logs) and host metrics (cpu, memory, disk, network) every 60 seconds. This built-in configuration is compiled into the agent binaries and managed internally.
/etc/google-cloud-ops-agent/config.yaml on Linux./etc/google-cloud-ops-agent/config.yaml (Linux) or C:\Program Files\Google\Cloud Operations\Ops Agent\config\config.yaml (Windows).This approach would be valid on systems or legacy tools that utilize a single editable template file with active inotify auto-reloading, but the Ops Agent explicitly forbids direct modification of built-in configurations.
In the Ops Agent configuration model, the service section connects data sources to data processing steps. Within service, the pipelines block defines named data pathways by referencing a list of receivers and an optional ordered list of processors.
service block only accepts two keys: receivers (specifying receiver IDs) and processors (specifying processor IDs). It does not support properties such as sampling_rate or collection_interval.metrics.receivers.<receiver_id>.collection_interval), not the pipeline definition.google-cloud-ops-agent service with systemctl is sufficient and avoids workload downtime.receivers.This approach would be appropriate if you wanted to disable metric collection entirely by overriding default_pipeline with an empty receivers list (receivers: []), or route metrics through custom processors, followed by a daemon restart.
In the Google Cloud Ops Agent architecture, processors are pipeline components used to transform, parse, modify, or exclude telemetry data after it has been gathered by a receiver. Fluent Bit is the underlying open-source technology embedded within the Ops Agent specifically dedicated to high-throughput log collection and log parsing.
hostmetrics), which interface directly with system resources./var/log/syslog), not metric telemetry. The OpenTelemetry Collector handles metrics and traces within the Ops Agent. Reloading Fluent Bit would have zero effect on system metric sampling.metrics_filter processor is designed for excluding specific metric patterns (exclude_metrics), not setting collection intervals.This approach would be appropriate if the goal were to filter out unwanted metric series using an exclude_metrics processor under metrics.processors to reduce Cloud Monitoring metric ingestion volume, rather than changing metric collection intervals.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated