0
0
GCPcloud~5 mins

Log Explorer and queries in GCP - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the purpose of Log Explorer in Google Cloud?
Log Explorer helps you find, view, and analyze logs from your Google Cloud resources in one place.
Click to reveal answer
beginner
What is a basic component of a Log Explorer query?
A basic query includes a filter that selects logs by resource type, severity, or text content.
Click to reveal answer
intermediate
How do you filter logs by severity in Log Explorer?
Use the filter expression like: severity>=ERROR to see logs with error or higher severity.
Click to reveal answer
beginner
What does the 'resource.type' field represent in a Log Explorer query?
It identifies the Google Cloud resource that produced the log, like 'gce_instance' for a VM.
Click to reveal answer
beginner
How can you use Log Explorer to find logs containing a specific text?
Include the text in quotes in the query, for example: "error connecting to database".
Click to reveal answer
Which field would you use to filter logs by the Google Cloud resource type?
AlogName
Bresource.type
Cseverity
Dtimestamp
What does the filter expression 'severity>=WARNING' do in Log Explorer?
AShows logs with severity exactly WARNING
BShows logs with severity lower than WARNING
CShows only WARNING logs
DShows logs with severity WARNING or higher
How do you search for logs containing the phrase 'timeout error'?
Atimeout error
Btimeout OR error
C"timeout error"
Dtimeout AND error
Which of these is NOT a valid Log Explorer query filter?
Atimestamp = "yesterday"
Bresource.type = "gce_instance"
Cseverity >= ERROR
DtextPayload : "failed"
What does the 'logName' field represent in a log entry?
AThe name of the log stream or log file
BThe severity level of the log
CThe resource type that generated the log
DThe timestamp of the log entry
Explain how to build a basic query in Log Explorer to find error logs from Compute Engine instances.
Think about filtering by resource type and severity level.
You got /4 concepts.
    Describe how you would search for logs containing a specific phrase and filter by time range in Log Explorer.
    Combine text search with timestamp filters.
    You got /4 concepts.