Table of Contents | ||||||
---|---|---|---|---|---|---|
|
Service description
This collector will retrieve the information stored in Google Cloud Platform (GCP), such as audit logs, networking, load balance, and more.
Data source description
The Google Cloud Platform (GCP) centralizes all the monitoring information from all services in the cloud catalog inside a service called Stackdriver.
There is certain information that is enabled by default and is free of charge. However, generating some other information will imply some costs and that's why it must be enabled manually. In both cases, the generated information (we will call them messages) will arrive at the Stackdriver service.
Note |
---|
There exist many more GCP services than the ones shown in the diagram, these are only a small sample. |
The Stackdriver service has different ways of exporting the information stored inside (structured in messages). In this case, it uses another GCP service called PubSub, which contains a "Topic" object that will receive a filtered set of messages from the Stackdriver service. Then, the GCP collector will retrieve all those messages from the "Topic" object using a subscription (concretely in "pull" mode):
The GCP collector that we provide processes the stored information and sends it to the Devo platform. Data will be sent to a central table within your Devo domain named cloud.gcp.
Service name definitions
Listed in the table below are the service names, details, and how the Devo platform treats the data.
Services | Details | Devo tables |
---|---|---|
Audit Resource | Get information on Cloud Audit Logs that maintain three audit logs for each Google Cloud project, folder, and organization: Admin Activity, Data Access, and System Event. Google Cloud services write audit log entries to these logs to help you answer the questions of "who did what, where, and when?" within your Google Cloud resources. |
|
Virtual Machines | Get information about the Virtual Machine Instance, CPU, Memory, and more. |
|
Redis | Get information on memory store for Redis instance's performance, and allows you to check in on your instances to make sure they're behaving as desired. |
|
Networking | Get information on memory store usage. |
|
Load Balance | Get information about the load balancer that distributes user traffic across multiple instances of your applications. |
|
Kubernetes Engine | Get information about Google Kubernetes Engine (GKE), which provides a managed environment for deploying, managing, and scaling your containerized applications using Google infrastructure. |
|
PubSub | Get information about the asynchronous messaging service. |
|
Setup
The collector will be executed inside of the Collector Server as well as a Standalone mode (docker container). Some configurations will be necessary for the proper functioning of the collector.
Source setup types
In order to have the GCP collector running in a proper way, the data source (in this case GCP) must have several service structures configured. Specifically, it is required to set subscription objects to pull mode.
The required GCP setup can be created either automatically or manually. Depending on a configuration file property called autoconfig, one mode or another will be used and the behavior will be the following:
Automatic | The autoconfig property must have the enabled option set to true. Also, the internal service definition should have a configuration class value set (this cannot be set by the customer). The autoconfiguration functionality will create different "sinks" using the predefined service definition or using some custom definitions from the configuration file. |
---|---|
Manual | The autoconfig property must have the enabled option set to false and any configuration class defined in the internal service definition will be ignored. Depending if the property subscription_name is set, two different behaviors will be applied:
|
Service types
The GCP collector must have at least one service entry in the services section. These services can be of two types:
Predefined services | These services will not require to set some properties in the configuration file since they are already internally defined. This is the list of predefined services:
|
---|---|
Custom services | These services will require some extra properties in the configuration file:
The syntax to be used in sink_filter_resource_* properties is detailed here. |
Credentials
Follow the next steps to create the Service Account that will be used to collect the alerts and enable the necessary API and scopes to use it.
Go to your Google GCP console project and open the left menu. Click IAM & Admin → Service Accounts.
Click on + Create Service Account to create the credentials.
Follow the 3 steps to create the credentials. Enter a name and click on Create. Steps 2 and 3 are optional, so you may just click Continue to go to step 3 and select Done.
Now you have to add the Keys to the service account that was previously createdand download it in JSON format. After clicking the Done button, you’ll be redirected to the services accounts of your project. Search the service account that you created and click it.
In the Service account details area, click ADD KEY → Create new key, select the JSON format, and click CREATE. Download the credentials file and move it to the
<any_directory>/devo-collectors/gcp/credentials/
directory.
Run the collector
Once the data source is configured, you can either send us the required information if you want us to host and manage the collector for you (Cloud collector), or deploy and host the collector in your own machine using a Docker image (On-premise collector).
Rw ui tabs macro | ||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
We use a piece of software called Collector Server to host and manage all our available collectors. If you want us to host this collector for you, get in touch with us and we will guide you through the configuration.
This data collector can be run in any machine that has the Docker service available because it should be executed as a docker container. The following sections explain how to prepare all the required setup for having the data collector running. StructureThe following directory structure will be required as part of the setup procedure (it can be created under any directory):
Devo credentialsIn Devo, go to Administration → Credentials → X.509 Certificates, download the Certificate, Private key and Chain CA and save them in Editing the config-gcp.yaml fileIn the config-gcp.yaml file, replace the The GCP collector has many different configurations. See some usage config examples and custom services below.
The custom configuration section can be set with many different values. Find below several examples of the custom configuration section and their impact on the different services involved.
Download the Docker imageThe collector should be deployed as a Docker container. Download the Docker image of the collector as a .tgz file by clicking the link in the following table:
Use the following command to add the Docker image to the system:
The Docker image can be deployed on the following services: DockerExecute the following command on the root directory
Docker ComposeThe following Docker Compose file can be used to execute the Docker container. It must be created in the
To run the container using docker-compose, execute the following command from the
|