Google Professional Cloud Network Engineer Question 562
Select 2Google Cloud PlatformYou are tasked with setting up DNS peering between two Google Cloud projects, Project-A and Project-B. Project-A hosts a private DNS zone for an internal domain, while Project-B needs to resolve queries for that domain. Which of the following steps are required to set up DNS peering correctly?
- A
Create a DNS peering zone in Project-B pointing to the private DNS zone in Project-A.
- B
Grant the 'DNS Peer' IAM role on the private DNS zone in Project-A to the service account of Project-B.
- C
Enable the Cloud DNS API in both Project-A and Project-B.
- D
Create a VPC peering connection between the VPC networks of Project-A and Project-B.
- E
Add a forwarding rule in Project-B's DNS configuration pointing to the public IP address of Project-A's DNS resolver.
Show answer and explanation
Correct answers: A, C
Explanation
To set up DNS peering, you need to create a DNS peering zone in the project where DNS queries will originate (Project-B in this scenario) and enable the Cloud DNS API in both projects. This ensures that DNS queries from Project-B can resolve the private DNS zone in Project-A. Other configurations, such as VPC peering or specific IAM roles, are not necessary for DNS peering to function.
- A. Correct.
Creating a DNS peering zone in Project-B pointing to the private DNS zone in Project-A is required to allow DNS queries to flow between the two projects.
- B. Incorrect.
Granting the 'DNS Peer' IAM role is not necessary for setting up DNS peering. DNS peering relies on network-level configuration and peering zones, not specific IAM roles on private DNS zones.
- C. Correct.
Enabling the Cloud DNS API in both projects is a required step because the DNS peering functionality depends on the Cloud DNS service being active in both projects.
- D. Incorrect.
A VPC peering connection is not required for DNS peering. DNS peering works across projects without needing VPC peering, as long as the DNS peering zone is configured correctly.
- E. Incorrect.
Forwarding rules pointing to public IPs are not part of DNS peering setup. DNS peering uses internal mechanisms to resolve queries between projects.