Logging

Database Migration Service uses Cloud Logging. See the Cloud Logging documentation for complete information and review the Cloud SQL sample queries.

To view logs for your AlloyDB for PostgreSQL cluster log entries:

Console

  1. Go to Logs Explorer
  2. In the Query tab, use the drop-down menus to compose the following query:
    • Resource: select AlloyDB Database. In the dialog, select a AlloyDB for PostgreSQL cluster.
    • Log names: scroll to the AlloyDB for PostgreSQL section and select appropriate log files for your cluster. For example:
      • alloydb.googleapis.com/postgres.log
    • Severity: select a log level.
    • Time range: select a preset or create a custom range.

gcloud

Use the gcloud logging command to view log entries. In the example below, replace PROJECT_ID. The limit flag is an optional parameter that indicates the maximum number of entries to return.

gcloud logging read "projects/[PROJECT_ID]/logs/alloydb.googleapis.com/postgres.log" --limit=10