Google Associate Cloud Engineer Question 303
Select 3Google Cloud PlatformYour team is troubleshooting a production issue in a Google Cloud Platform environment, and you need to view and filter logs from multiple services to identify the root cause. Which of the following steps can you take to effectively filter and view logs in Cloud Logging using the Logs Explorer?
- A
Use the 'Basic' mode to filter logs by log name, severity, and time range.
- B
Utilize the 'Advanced' mode to write queries using Logging Query Language for complex filtering.
- C
Enable the Legacy Logs Viewer to access more detailed filtering options.
- D
Create a custom dashboard in Cloud Monitoring to visualize the log data.
- E
Set up a sink to export logs to BigQuery for detailed analysis.
Show answer and explanation
Correct answers: A, B, E
Explanation
To effectively filter and view logs in Cloud Logging, engineers should utilize the 'Basic' and 'Advanced' modes in the Logs Explorer for immediate filtering and complex query capabilities. Additionally, exporting logs to BigQuery can facilitate more detailed analysis, which is particularly useful for comprehensive troubleshooting.
- A. Correct.
The 'Basic' mode in Logs Explorer allows you to filter logs by specific criteria like log name, severity, and time range, which is useful for initial filtering.
- B. Correct.
The 'Advanced' mode in Logs Explorer allows you to use the Logging Query Language (LQL) for more detailed and complex filtering, which is essential for in-depth troubleshooting.
- C. Incorrect.
The Legacy Logs Viewer is deprecated and no longer provides more detailed filtering options; it's recommended to use the Logs Explorer.
- D. Incorrect.
While creating a custom dashboard can help visualize log data, it doesn't directly assist in filtering logs within Cloud Logging.
- E. Correct.
Setting up a sink to export logs to BigQuery allows for detailed analysis and querying of logs, which can be useful for complex troubleshooting scenarios.