How to monitor Couchbase with Google Cloud Ops
You can now easily monitor Couchbase metrics and logs in Google Cloud. Our logging and monitoring of Google Cloud contributions are available through the Google Ops Agent GitHub repository. You can check it out here!
The Google Ops Agent uses the built-in Prometheus exporter and receiver to monitor Couchbase sources running Couchbase 7.0. You can find documentation on the Prometheus exporter in the Couchbase documentation. Information on the Prometheus receiver is available in the observIQ OpenTelemetry distribution on GitHub.
What signals matter?
Couchbase is a distributed noSQL database. It’s easy to distribute across multiple systems and scales. Signals that are often monitored on Couchbase include evictions, errors, and memory usage, as well as access logs:
- Spiking Evictions
- If ‘bucket.item.ejection.count’ spikes, it could show unexpected memory pressure.
- Unrecoverable OOM Errors
- If ‘bucket.error.oom.count’ signals unrecoverable errors, it indicates that the couchbase server is running out of memory and is unrecoverable.
- High Memory Usage
- If the ‘bucket.memory.usage’ bytes are higher than anticipated, it could show that the bucket needs to be allocated more memory.
- Couchbase HTTP Access Logs
- These access logs indicate what kind of traffic the couchbase is undergoing via its REST API. It could be an indication of bad requests or if things are operating normally.
All of the above categories can be gathered with the Couchbase receiver – so let’s get started.
Related Content: Five Things to Know About Google Cloud Operations Suite and BindPlane
Before you begin
If you’re already a Google Cloud user, You can set up your Google Cloud workspace to receive metrics and logs by following Google’s Ops Agent documentation. You can find installation and setup instructions here.
Configuring the Couchbase receiver
Navigate to your Ops Agent configuration file.
- /etc/google-cloud-ops-agent/config.yaml(Linux)
- C:\Program Files\Google\Cloud Operations\Ops Agent\config\config.yaml (Windows)
Edit the configuration file to include the Couchbase receiver as shown below:
1metrics:
2 receivers:
3 couchbase:
4 type: couchbase
5 username: admin
6 password: password
7 collection_interval: 30s
In the same yaml config file, add Couchbase to your service pipeline so it looks similar to the following. Note that your processors and exporters will likely differ, and you must insert your admin username and password.
1service:
2 pipelines:
3 couchbase:
4 receivers:
5 - couchbase
6
7logging:
8 receivers:
9 couchbase_general:
10 type: couchbase_general
11 couchbase_http_access:
12 type: couchbase_http_access
13 couchbase_goxdcr:
14 type: couchbase_goxdcr
15 service:
16 pipelines:
17 couchbase:
18 receivers:
19 - couchbase_general
20 - couchbase_http_access
21 - couchbase_goxdcr
You can edit the config file further to include specific labels under the “processors” field, but the Google Ops Agent already has default labels for the data collected.
Relevant Editable Fields in Config:
Viewing the telemetry collected
If you follow the steps above, the following Couchbase metrics will now be delivered to your preferred destination.
List of Metrics Collected:
Related Content: How to monitor Oracle DB with Google Cloud Platform
observIQ’s distribution of the OpenTelemetry collector is a game-changer for companies looking to implement OpenTelemetry standards. The single-line installer, seamlessly integrated receivers, exporter, and processor pool make working with this collector simple. Follow this space to keep up with all our future posts and simplified configurations for various sources. For questions, requests, and suggestions, contact our support team at support@observIQ.com.