PAS-C01 Technology Practice Question
A company wants to automate the installation of SAP HANA on AWS using CloudFormation. Which AWS resource should be used to run a script that downloads and installs SAP HANA software on an EC2 instance after the instance is launched?
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
✓
AWS::CloudFormation::CreationPolicy with cfn-signal
AWS CloudFormation's CreationPolicy with cfn-signal allows you to control the stack creation process by waiting for a signal from the EC2 instance after it has completed its configuration. When using a CreationPolicy, CloudFormation will not mark the resource as created until it receives a signal (e.g., via cfn-signal) indicating that the installation script has finished. This is ideal for automating SAP HANA installations where you need to ensure the software is fully installed before proceeding. Option A is incorrect because AWS::CloudFormation::Init (cfn-init) is used to install packages, create files, and run commands during instance launch, but it does not provide a mechanism for CloudFormation to wait for the completion of long-running scripts; it runs as part of the user data and returns immediately. Option C is incorrect because while a Lambda function can be triggered by EC2 state changes, it does not integrate directly with CloudFormation's stack creation process to signal completion. You would need additional custom logic to send a signal back to CloudFormation, making it less straightforward than using CreationPolicy. Option D is incorrect because EC2 User Data runs once at instance launch, but CloudFormation does not inherently wait for user data scripts to finish. Without a CreationPolicy or similar mechanism, CloudFormation will proceed to the next resource immediately after launching the instance, even if the script is still running.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
AWS::CloudFormation::Init (cfn-init)
Why it's wrong here
cfn-init configures instances but lacks built-in completion signaling.
- ✓
AWS::CloudFormation::CreationPolicy with cfn-signal
Why this is correct
CreationPolicy waits for signals from cfn-signal after script completes.
- ✗
AWS Lambda function triggered by EC2 state change
Why it's wrong here
Lambda can be triggered but adds complexity; not native to CloudFormation.
- ✗
EC2 User Data
Why it's wrong here
User Data runs at launch but CloudFormation cannot wait for its completion.
Quick reference
Cloud Service Model Comparison
| Model | You Manage | Provider Manages | Examples |
|---|---|---|---|
| IaaS | OS, runtime, apps, data | Hardware, hypervisor, networking | EC2, Azure VMs, GCP Compute Engine |
| PaaS | Apps and data | OS, runtime, middleware, hardware | Elastic Beanstalk, Azure App Service |
| SaaS | Data and settings only | Everything else | Microsoft 365, Salesforce, Workday |
| FaaS / Serverless | Function code only | Infra, scaling, runtime | Lambda, Azure Functions, Cloud Run |
| CaaS | Containers and apps | Kubernetes, OS, hardware | EKS, AKS, GKE |
Go deeper
Related to this question
About these practice questions
One of 1,616 original PAS-C01 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This PAS-C01 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 PAS-C01 exam.