Google Professional Cloud DevOps Engineer Question 7
Select 3Google Cloud PlatformYou are a DevOps engineer responsible for monitoring and logging across multiple Google Cloud projects. Your organization wants to centralize logs and metrics for better visibility and analysis. What combination of actions should you take to ensure centralized multi-project monitoring and logging?
- A
Create a centralized Logging bucket in a designated 'monitoring' project and configure log sinks in each project to route logs to the centralized bucket.
- B
Set up a Cloud Monitoring Workspace in a dedicated project and add all other projects as monitored projects to the workspace.
- C
Enable Cloud Logging and Cloud Monitoring APIs only in the 'monitoring' project to reduce API usage in other projects.
- D
Use BigQuery to export logs from each project into separate datasets for analysis instead of routing logs to a centralized Logging bucket.
- E
Configure IAM permissions to allow the monitoring team to access the centralized Logging bucket and Monitoring Workspace.
Show answer and explanation
Correct answers: A, B, E
Explanation
To achieve centralized multi-project monitoring and logging, you need to configure a centralized Logging bucket and a Cloud Monitoring Workspace in a designated project. Logs from all projects are routed to the centralized bucket, while monitoring data is aggregated in the Monitoring Workspace. Proper IAM permissions ensure that the monitoring team can access these centralized resources. Disabling APIs or using BigQuery alone does not fulfill the requirements for real-time centralized monitoring and logging.
- A. Correct.
This is correct. Creating a centralized Logging bucket and routing logs from multiple projects ensures that logs are aggregated in one location for easier management and analysis.
- B. Correct.
This is correct. A Cloud Monitoring Workspace is designed to unify monitoring data across multiple Google Cloud projects, enabling centralized monitoring.
- C. Incorrect.
This is incorrect. Cloud Logging and Monitoring APIs must be enabled in all projects where logging and monitoring data originate. Disabling them in non-monitoring projects would disrupt data collection.
- D. Incorrect.
This is incorrect. While BigQuery can be used for log analysis, it doesn't provide the real-time centralized logging and monitoring capabilities required for this scenario.
- E. Correct.
This is correct. Proper IAM permissions are essential to allow the monitoring team to access centralized resources such as the Logging bucket and Monitoring Workspace.