Question 47 of 1,616
Troubleshooting and OptimizationhardMultiple ChoiceObjective-mapped

Quick Answer

The correct answer is that the ECS Fargate task is running in a private subnet without a NAT gateway. Even though the task has a public IP assigned, a private subnet has no direct route to an internet gateway, so outbound traffic to the external API is dropped by the subnet’s route table, causing the intermittent timeouts. This scenario is a classic trap on the AWS Certified Developer Associate DVA-C02 exam: it tests your understanding that a public IP on a Fargate task is irrelevant in a private subnet—only a NAT gateway or VPC endpoint can provide outbound internet connectivity from there. The exam often pairs this with security group rules that look correct, luring you away from the subnet routing issue. Remember the mnemonic: “Public IP on a private subnet is like a car with no road—it can’t go anywhere.”

DVA-C02 Troubleshooting and Optimization Practice Question

This DVA-C02 practice question tests your understanding of troubleshooting and optimization. Match the stated requirement to the specific cloud service, access model, or configuration option — many options are valid in isolation but not for this scenario. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.

An application running on Amazon ECS Fargate is experiencing intermittent connection timeouts when calling an external API. The task has a public IP and a security group that allows outbound HTTPS. What is the most likely cause?

Clue words in this question

Noticing these words before you look at the options changes how you read each choice.

  • Clue: "most likely"

    Why it matters: Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

Question 1hardmultiple choice
Full question →

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

The task is running in a private subnet without a NAT gateway.

Option D is correct because ECS Fargate tasks running in a private subnet do not have direct internet access. Without a NAT gateway, outbound traffic to the external API is routed to the subnet’s route table, which lacks an internet gateway target, causing connection timeouts. The task’s public IP assignment is irrelevant in a private subnet, as the subnet itself has no route to the internet.

Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Answer analysis

Option-by-option breakdown

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

  • The ECS service is not configured to auto-assign public IP.

    Why it's wrong here

    Auto-assign public IP is for public subnets; in private subnets, NAT is required.

  • The task's security group does not allow inbound traffic.

    Why it's wrong here

    Outbound traffic is allowed by default; inbound is not needed for outbound connections.

  • The security group outbound rules are misconfigured.

    Why it's wrong here

    Security groups allow all outbound traffic by default.

  • The task is running in a private subnet without a NAT gateway.

    Why this is correct

    Private subnets need a NAT gateway for outbound internet access.

    Clue confirmation

    The clue word "most likely" in the question point toward this answer.

    Related concept

    Read the scenario before looking for a memorised answer.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The trap here is that candidates assume a public IP on the task guarantees internet access, overlooking that the subnet’s route table determines whether traffic can reach the internet, and a private subnet without a NAT gateway blocks all outbound internet traffic regardless of the task’s public IP assignment.

Detailed technical explanation

How to think about this question

In Amazon ECS Fargate, tasks in a private subnet rely on a NAT gateway or NAT instance to translate private IPs to a public IP for internet-bound traffic. Without this, the task’s outbound packets are dropped at the subnet’s route table because the default route (0.0.0.0/0) points to a NAT gateway or internet gateway only in public subnets. The intermittent nature of timeouts can occur if the external API has rate limiting or if the task occasionally retries, but the root cause is the missing NAT gateway.

KKey Concepts to Remember

  • Read the scenario before looking for a memorised answer.
  • Find the constraint that changes the correct option.
  • Eliminate answers that are true in general but not in this case.

TExam Day Tips

  • Watch for words such as best, first, most likely and least administrative effort.
  • Review why wrong options are wrong, not only why the correct option is correct.

Key takeaway

Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Real-world example

How this comes up in practice

A company's IT admin needs to give a contractor read-only access to production logs without sharing account credentials. Using role-based access control (RBAC) and temporary scoped permissions — not a permanent shared password — is the correct pattern. Questions like this test whether you can apply least-privilege access across cloud identity services.

What to study next

Got this wrong? Here's your next step.

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Related practice questions

Related DVA-C02 practice-question pages

Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.

Practice this exam

Start a free DVA-C02 practice session

Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.

FAQ

Questions learners often ask

What does this DVA-C02 question test?

Troubleshooting and Optimization — This question tests Troubleshooting and Optimization — Read the scenario before looking for a memorised answer..

What is the correct answer to this question?

The correct answer is: The task is running in a private subnet without a NAT gateway. — Option D is correct because ECS Fargate tasks running in a private subnet do not have direct internet access. Without a NAT gateway, outbound traffic to the external API is routed to the subnet’s route table, which lacks an internet gateway target, causing connection timeouts. The task’s public IP assignment is irrelevant in a private subnet, as the subnet itself has no route to the internet.

What should I do if I get this DVA-C02 question wrong?

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Are there clue words in this question I should notice?

Yes — watch for: "most likely". Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

What is the key concept behind this question?

Read the scenario before looking for a memorised answer.

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

1 more ways this is tested on DVA-C02

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. An application running on Amazon ECS with Fargate is unable to connect to the internet. The task definition does not have any network configuration specified. What is the MOST likely cause?

easy
  • A.The security group associated with the task does not allow outbound traffic.
  • B.The task is not assigned a public IP address and is in a private subnet.
  • C.The ECS service discovery is not configured.
  • D.The VPC does not have an internet gateway attached.

Why B: Option C is correct because Fargate tasks running in awsvpc network mode need a route to the internet via a NAT gateway if they are in private subnets. Option A is wrong because tasks can access the internet without an internet gateway if they have a public IP and are in a public subnet. Option B is wrong because security groups control inbound/outbound traffic, but they do not provide internet connectivity. Option D is wrong because ECS service discovery is for service-to-service communication within the VPC.

Keep practising

More DVA-C02 practice questions

Last reviewed: Jun 24, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

This DVA-C02 practice question is part of Courseiva's free Amazon Web Services 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 DVA-C02 exam.