This page provides information about logging and monitoring metrics for Cloud DNS including public zones, private zones, and forwarding zones. This page also provides instructions for monitoring the propagation of your public DNS changes.
Use Cloud DNS logging
Cloud DNS logging tracks queries that name servers resolve for your Virtual Private Cloud (VPC) networks, as well as queries from an external entity directly to a public zone.
Logged queries can come from Compute Engine virtual machine (VM) instances, Google Kubernetes Engine containers in the same VPC network, peering zones, or on-premises clients that use inbound DNS forwarding. Private DNS zones, forwarding DNS zones, alternative name servers, internal Google Cloud DNS zones, or external DNS zones might eventually resolve the queries.
Log records belong to the project that owns the network or public zone that carried the request. In the case of Shared VPC, the log records belong to the host project because the host project owns the network.
Enable logging for private managed zones
Use DNS policies to enable or disable logging for your networks. When you enable query logging, every DNS query to a Cloud DNS private managed zone is logged.
To enable logging for a network that does not have a DNS policy, complete the following steps.
Console
In the Google Cloud console, go to the Create a DNS policy page.
For Name, enter a name for your policy.
Optionally, enter a description for Description.
For Logs, select On.
In the Networks section, click Add networks and choose the networks you need.