nerdexam
GoogleGoogle

PROFESSIONAL-CLOUD-DEVELOPER · Question #383

PROFESSIONAL-CLOUD-DEVELOPER Question #383: Real Exam Question with Answer & Explanation

The correct answer is C: Set up VPC Network Peering between your VPC and the VPC where the Cloud SQL instance is. VPC Network Peering is required to enable private IP connectivity between resources in different VPC networks. Without peering, you cannot reach the private IP address of the Cloud SQL instance from another VPC.

Integrating Google Cloud Services

Question

You are developing an application that needs to connect to a Cloud SQL for PostgreSQL database by using the Cloud SQL Auth Proxy. The Cloud SQL Auth Proxy is hosted in a different Google Cloud VPC network. The Cloud SQL for PostgreSQL instance has public and private IP addresses. You are required to use the private IP for security reasons. When testing the connection to the Cloud SQL instance, you can connect by using the public IP address, but you are unable to connect by using the private IP address. How should you fix this issue?

Options

  • ARun the Cloud SQL Auth Proxy as a background service.
  • BAdd the --private-ip option when starting the Cloud SQL Auth Proxy.
  • CSet up VPC Network Peering between your VPC and the VPC where the Cloud SQL instance is
  • DGrant yourself the IAM role that provides access to the Cloud SQL instance.

Explanation

VPC Network Peering is required to enable private IP connectivity between resources in different VPC networks. Without peering, you cannot reach the private IP address of the Cloud SQL instance from another VPC.

Topics

#Cloud SQL Auth Proxy#VPC Network Peering#Private IP Connectivity#Database Networking

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-CLOUD-DEVELOPER PracticeBrowse All PROFESSIONAL-CLOUD-DEVELOPER Questions