Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Amazon SOA-C03 Exam - Topic 1 Question 21 Discussion

Posted by Lennie on Oct 15, 2026 at 09:09 PM

A CloudOps engineer is examining the following AWS CloudFormation template:

AWSTemplateFormatVersion: '2010-09-09'

Description: 'Creates an EC2 Instance'

Resources:

EC2Instance:

Type: AWS::EC2::Instance

Properties:

ImageId: ami-79fd7eee

InstanceType: m5n.large

SubnetId: subnet-1abc3d3fg

PrivateDnsName: ip-10-24-34-0.ec2.internal

Tags:

- Key: Name

Value: !Sub "${AWS::StackName} Instance"

Why will the stack creation fail?

Suggested Answer: C

The PrivateDnsName attribute of an EC2 instance is automatically assigned by AWS at launch time and is a read-only property. CloudFormation does not allow users to specify this value manually.

Including PrivateDnsName in the EC2 instance properties causes validation to fail during stack creation. Outputs and Parameters sections are optional, and the VPC is implicitly defined through the subnet ID.

Therefore, attempting to set PrivateDnsName results in stack creation failure.


Get Premium SOA-C03 Questions as Interactive Web-Based Practice Test or PDF Real Exam Format Detailed Explanations Instant Access Get Your Practice Test
0 comments · newest first

Currently there are no comments in this discussion, be the first to comment!

0/2000 characters

Save Cancel