QuestionQ39

VerifiedImplementing observability practices and troubleshooting issues

You are setting up Cloud Logging for a new application running on a Compute Engine instance that has a public IP address. A user-managed service account is attached to the instance. You have confirmed that the required agents are running on the instance, but no log entries from the instance appear in Cloud Logging. You want to fix the issue by using Google-recommended practices. What should you do?

Explanation

The attached service account must have the Logs Writer role (roles/logging.logWriter), which grants logging.logEntries.create to write log entries. Attached service-account credentials are the recommended authentication mechanism for Compute Engine workloads; exporting a service-account key is unnecessary. Private Google Access is not required when the instance has a public IP address.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!