Courseiva

Google PCA Manage and provision cloud infrastructure Practice Question

A Cloud Function fails to connect to a Cloud SQL instance. The Cloud SQL instance has a private IP. What should the developer check?

⚠ Common exam trap

Google Cloud often tests the misconception that either a VPC connector or the Cloud SQL Proxy alone is sufficient, when in fact both the network path (via VPC connector or proxy in the VPC) and correct IAM permissions are required for private IP connectivity.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

Ensure either Cloud SQL Proxy is running or a VPC connector is configured, and IAM permissions are correct.

A Cloud Function with a private IP Cloud SQL instance requires either the Cloud SQL Proxy (which uses the Cloud SQL Auth proxy to establish an encrypted connection via the public IP, but if the instance has only a private IP, the proxy must be run within the same VPC) or a VPC connector to enable private networking. Additionally, proper IAM permissions (e.g., Cloud SQL Client role) are necessary for the proxy or connector to authenticate and connect. Without both the network path and IAM permissions, the connection will fail.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    Ensure the Cloud SQL Proxy is running and configured.

    Why it's wrong here

    Cloud SQL Proxy is not required for private IP; VPC connector is needed.

  • ✗

    Verify the Cloud Function's network settings.

    Why it's wrong here

    Too vague.

  • ✓

    Ensure either Cloud SQL Proxy is running or a VPC connector is configured, and IAM permissions are correct.

    Why this is correct

    Both connectivity and authorization must be in place.

  • ✗

    Configure a VPC connector for the Cloud Function.

    Why it's wrong here

    While necessary, it's not the only thing to check; also need IAM.

Go deeper

Related to this question

About these practice questions

This PCA question is part of Courseiva's 807-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This PCA practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the PCA exam.