All Linux Foundation / CNCF exams
Free CNPA practice test: 30 questions with answers
30 original questions for Certified Cloud Native Platform Engineering Associate, drawn from every topic area. Answer each one to see whether you got it right and why. No sign-up.
- Free questions
- 30
- Full bank
- 100 questions
All 30 CNPA questions with answers
The same questions as the test above, grouped by exam topic. Open any question to see the answer and explanation.
Platform Engineering Core Fundamentals (5 questions)
Question 1
A platform team wants developers to describe the desired state of their services in version-controlled files instead of running imperative commands against the cluster. Which principle does this apply?
- ADeclarative resource management
- BImperative scripting with manual sequencing
- CAd hoc configuration through a shared terminal
- DSnapshot-based recovery of server disks
Show answer and explanationHide answer
Correct answer: ADeclarative management describes the desired state, and a controller works to make the actual state match it. Imperative scripts and ad hoc terminal changes record steps rather than intent and drift over time.
Question 2
A Kubernetes controller compares the state recorded for a Deployment with the state actually running and takes actions to close the gap. What is this process called?
- AThe scheduling cycle only
- BThe garbage collection sweep
- CThe reconciliation loop
- DThe admission chain
Show answer and explanationHide answer
Correct answer: CThe reconciliation loop repeatedly observes the actual state, compares it with the desired state, and acts to converge them. Admission controllers validate or mutate requests, and garbage collection removes unused objects.
Question 3
Which two statements describe the relationship between DevOps practices and a platform team? (Choose two.)
- AContinuous feedback between developers and platform operators is a core DevOps practice that the platform should support
- BPlatforms work best when each product team builds its own unique deployment stack from scratch
- CA platform team reduces the cognitive load on product teams by offering shared, self-service capabilities
- DPlatform teams replace the need for shared responsibility for running services in production
Show answer and explanationHide answer
Correct answer: A, CA platform reduces cognitive load by providing paved paths and feedback loops are central to DevOps. Platforms do not remove shared responsibility, and bespoke stacks per team work against standardization.
Question 4
A company runs the same application in development, staging, and production clusters with different replica counts and secrets. Which approach keeps the environments consistent while allowing these differences?
- ARely on engineers to remember the environment differences for each release and apply them
- BStore a common base configuration and apply environment-specific overlays or values
- CMaintain three independent copies of each manifest in separate repositories with no shared source
- DUse the production manifests as the template and edit a copy by hand in each cluster later
Show answer and explanationHide answer
Correct answer: BA shared base with environment overlays or values keeps the common definition in one place and isolates the variations. Separate hand-maintained copies and manual memory lead to configuration drift.
Question 5
In GitOps, which component continuously compares the desired state in a Git repository with the live cluster and applies changes to close any difference?
- AA DNS resolver for service names
- BA container image registry
- CA continuous integration runner that runs unit tests
- DA GitOps controller such as Argo CD or Flux
Show answer and explanationHide answer
Correct answer: DGitOps controllers such as Argo CD and Flux pull the desired state from Git and reconcile the cluster to it. Registries store images, test runners verify code, and DNS resolves names, so none of them enforce cluster state.
Platform Observability, Security, and Conformance (5 questions)
Question 6
A microservice team wants to understand why one request took 900 milliseconds across five services. Which observability signal is designed for this purpose?
- AA list of container image tags and digests from the registry
- BAggregate CPU and memory usage graphs for each worker node sampled every 60 seconds
- CThe configuration file of the external cloud load balancer
- DDistributed traces that link spans across services for a single request
Show answer and explanationHide answer
Correct answer: DTraces record the timing and path of one request through each service as linked spans, which makes latency hotspots visible. Node CPU graphs and image lists do not show per-request paths.
Question 7
A platform team wants applications to emit telemetry in a vendor-neutral format that can be routed to several backends. Which CNCF project is the standard for this?
- AArgo CD
- BEnvoy Gateway
- COpenTelemetry
- DHelm
Show answer and explanationHide answer
Correct answer: COpenTelemetry defines vendor-neutral APIs, SDKs, and a collector for traces, metrics, and logs. Helm packages applications, Argo CD performs GitOps delivery, and Envoy Gateway handles traffic routing.
Question 8
A security team needs services in a cluster to authenticate each other and encrypt traffic between them. Which two approaches provide this? (Choose two.)
- AA shared bearer token stored as an environment variable in every service
- BPublishing every service on a public IP address
- CMutual TLS with a workload identity for each service
- DA service mesh policy that enforces mTLS through sidecar proxies
Show answer and explanationHide answer
Correct answer: C, DMutual TLS authenticates both peers and encrypts traffic, and a service mesh can enforce it transparently through sidecars. A shared token does not authenticate individual peers, and public exposure weakens security.
Question 9
A platform team wants to block Kubernetes workloads that run as root or use privileged containers, enforced at admission time. Which kind of tool does this?
- AA policy engine such as OPA Gatekeeper or Kyverno
- BA DNS load balancer
- CA metrics dashboard
- DA container image scanner that runs only once a month
Show answer and explanationHide answer
Correct answer: APolicy engines evaluate resources during admission and reject those that violate rules, such as privileged containers. Dashboards and scanners report on state, and DNS load balancing does not enforce policy.
Question 10
A team is securing its CI/CD pipeline. Which measure most directly reduces the risk that a compromised build injects malicious code into a release?
- ASigning build artifacts and verifying signatures before deployment
- BSharing one long-lived pipeline token among the developers
- CDisabling logs of pipeline runs to reduce retention costs
- DAllowing every commit to deploy directly to production
Show answer and explanationHide answer
Correct answer: AArtifact signing and verification ensure that only artifacts produced by trusted pipelines are deployed. Shared credentials, disabled logs, and direct deployment all increase the attack surface.
Continuous Delivery & Platform Engineering (5 questions)
Question 11
A team is choosing deployment strategies for a customer-facing service. Which strategy sends a small share of live traffic to a new version first so that problems are detected before a full rollout?
- ADeploying only to a test cluster and never to production
- BBig-bang replacement of all instances at once
- CDeleting the old version before deploying the new one
- DCanary release
Show answer and explanationHide answer
Correct answer: DA canary release routes a small percentage of traffic to the new version and expands only if metrics stay healthy. Big-bang and delete-first approaches expose all users at once, and test-only deployment does not validate production behavior.
Question 12
During an incident in a GitOps-managed cluster, an engineer edits a Deployment directly with kubectl to restore service. What is the main risk of this action?
- AThe GitOps controller may revert the change to match Git, and the cluster will drift from the recorded state
- BThe change is mirrored to every other environment instantly through the shared Helm chart values repository across clusters
- CThe cluster becomes immune to future drift once the kubectl patch is saved, since live objects are no longer compared with Git
- DThe change is automatically recorded in Git with the correct author once the manual edit is detected by the sync loop
Show answer and explanationHide answer
Correct answer: AA GitOps controller reconciles the cluster back to the desired state in Git, so a manual edit can be overwritten and the source of truth is bypassed. Manual edits are not committed to Git automatically, and they do not spread across environments.
Question 13
A pipeline runs unit tests, builds an image, and then runs a deployment stage that promotes the same image digest through staging to production. What is the main benefit of promoting the same artifact?
- ARebuilding the image in each environment is required by the security policy
- BIt allows each environment to deploy a different binary for the same release tag
- CThe tested artifact is the one deployed, which avoids differences introduced by rebuilding
- DIt removes the need for automated unit and integration tests in later stages
Show answer and explanationHide answer
Correct answer: CPromoting a single immutable digest means what was tested is what runs in production. Rebuilding per environment can introduce different dependencies or build results, which breaks that guarantee.
Question 14
Which two practices help a CI pipeline recover quickly when a change breaks the build or deployment? (Choose two.)
- ARunning automated rollback or fast forward-fix procedures that are rehearsed in advance
- BBatching months of changes into one release to reduce the number of pipeline runs
- CSkipping failing tests so that the pipeline keeps moving
- DKeeping the main branch always deployable with small, frequent changes
Show answer and explanationHide answer
Correct answer: A, DSmall, frequent changes and practiced rollback or forward-fix procedures shorten the time to recover. Large batches and skipped tests make failures harder to isolate and more likely to reach users.
Question 15
A release causes a spike in errors, and the on-call engineer must restore service quickly. Which action should the pipeline and platform support first?
- ADisabling the monitoring alerts so the error rate stops appearing on the status page for customers
- BWaiting for a complete rebuild of the image from source and the test suite before taking action
- CRolling back to the last known good version through the same automated delivery path
- DEditing production code by hand on the server without a record during the incident window
Show answer and explanationHide answer
Correct answer: CRolling back to the last known good version through the delivery path restores service fast and keeps the change recorded. Manual edits, long rebuilds, and disabled monitoring each make recovery slower or hide the problem.
Platform APIs and Provisioning Infrastructure (5 questions)
Question 16
A platform team wants developers to request a managed database through a Kubernetes API object rather than a ticket. Which extension mechanism provides a new custom resource type for this?
- ANode labels applied by hand
- BPod security standards
- CConfigMaps containing free-form text
- DCustom Resource Definitions (CRDs)
Show answer and explanationHide answer
Correct answer: DCRDs extend the Kubernetes API with new resource kinds, which a controller can then reconcile into real infrastructure. ConfigMaps store data rather than define types, labels describe nodes, and pod security standards govern pod settings.
Question 17
A custom controller watches a custom resource and creates, updates, or deletes cloud resources to match its specification. What is this pattern called?
- AThe sidecar pattern
- BThe fan-out queue pattern
- CThe blue-green deployment pattern
- DThe Kubernetes operator pattern
Show answer and explanationHide answer
Correct answer: DAn operator combines a custom resource with a controller that reconciles it, encoding operational knowledge for a managed application or resource. The other patterns describe different topologies or deployment strategies.
Question 18
A team wants infrastructure such as networks and storage accounts to be created from declarative definitions and tracked over time. Which approach best fits this need?
- ARunning one-off shell commands on a single developer laptop with local credentials and no record of what was changed or why
- BInfrastructure as code with declarative definitions that are versioned and applied through a reconciling tool
- CCopying resource IDs and network ranges from a blog post written for an older provider version and pasting them into the templates
- DCreating each resource manually in the cloud console and recording screenshots for later reference
Show answer and explanationHide answer
Correct answer: BDeclarative infrastructure as code is versioned, reviewable, and can be reconciled, which makes changes repeatable and auditable. Console clicks, one-off commands, and copied IDs are not reproducible.
Question 19
A controller's reconcile function may run many times for the same object. Why must it be written to be idempotent?
- AEach run must create a new resource so that the history of changes stays complete for auditing
- BReconcile functions must fail on their first attempt, so each object is requeued with a backoff timer
- CIdempotency matters for read-only controllers that observe objects and do not write back to the API server
- DRepeated runs with the same desired state must produce the same result without creating duplicates or errors
Show answer and explanationHide answer
Correct answer: DReconciliation is repeated on events and retries, so the same input should lead to the same final state without side effects piling up. Creating new resources each run causes duplicates, and idempotency matters for controllers that write too.
Question 20
A team defines a Custom Resource Definition and wants the API server to reject objects that omit a required field or use the wrong type. Which part of the CRD provides this?
- AThe finalizer list field
- BThe printer column settings
- CThe openAPIV3Schema validation
- DThe ownerReferences list in metadata
Show answer and explanationHide answer
Correct answer: CopenAPIV3Schema describes the structure and types the API server validates against when objects are created or updated. Printer columns affect display, owner references manage garbage collection, and finalizers control deletion.
IDPs and Developer Experience (5 questions)
Question 21
A platform team wants developers to find services, documentation, and ownership information from one place. Which kind of tool is designed for this?
- AA network packet capture appliance
- BA developer portal and service catalog
- CA PostgreSQL streaming replication monitor
- DA nightly batch tape backup system
Show answer and explanationHide answer
Correct answer: BA developer portal with a service catalog centralizes discovery of services, owners, and documentation, which reduces friction. Packet capture, tape backup, and replication monitoring do not serve discovery.
Question 22
Which two features are typical of an internal developer portal? (Choose two.)
- AA hardware inventory of data center racks
- BA software catalog that lists services, owners, and documentation
- CSoftware templates that scaffold new services with the approved pipeline and configuration
- DA schedule for tape backups of the office printers
Show answer and explanationHide answer
Correct answer: B, CA developer portal typically provides a service catalog for discovery and templates that scaffold new services on paved paths. Printer backups and rack inventories are not developer portal features.
Question 23
A platform team adds AI-assisted suggestions that propose remediation steps for failing deployments. What guardrail is most appropriate?
- AAutomatic application of each suggestion to production without review
- BA human review step and policy checks before any suggested change is applied
- CGranting the model cluster-admin rights across the production fleet so it can act faster
- DDisabling logs so the model can see fewer details in the audit trail and rollout history
Show answer and explanationHide answer
Correct answer: BKeeping a human in the loop and enforcing policy checks limits the impact of wrong suggestions and keeps accountability clear. Automatic production changes, disabled logs, and broad admin rights all increase risk.
Question 24
In Backstage, which format is used for the entity descriptor files that register services in the software catalog?
- ABinary protocol buffers only
- BPrinted PDF
- CYAML
- DSpreadsheet macros
Show answer and explanationHide answer
Correct answer: CBackstage catalog entities are described in YAML files that are registered with the catalog. The other formats are not used for these descriptors.
Question 25
Which two benefits does a self-service developer portal typically provide? (Choose two.)
- AFewer tickets for routine requests such as creating a new service from a template
- BElimination of all documentation needs across the organization
- CA guarantee that no incidents will occur
- DFaster onboarding through documented, discoverable services and templates
Show answer and explanationHide answer
Correct answer: A, DDiscoverable documentation and templates speed onboarding and reduce routine ticket volume. A portal does not remove documentation needs or guarantee zero incidents.
Measuring your Platform (5 questions)
Question 26
A platform team wants measures of software delivery performance that reflect throughput and stability. Which two are DORA metrics? (Choose two.)
- ALead time for changes
- BNumber of tickets closed each week
- CLines of code written by the platform team
- DDeployment frequency
Show answer and explanationHide answer
Correct answer: A, DDeployment frequency and lead time for changes are two of the four DORA throughput and stability measures. Ticket counts and code volume measure activity rather than delivery performance.
Question 27
A platform team wants to show its effect on team productivity. Which measure directly reflects how quickly new engineers can deliver their first change using the platform?
- ANumber of dashboards created by the platform team in each quarter
- BOnboarding time from account creation to the first production deployment
- CNumber of platform team meetings per week with product leads
- DTotal number of merged Git commits in the platform repository
Show answer and explanationHide answer
Correct answer: BOnboarding time to first deployment reflects how well the platform removes friction for product teams. Meeting counts, commit totals, and dashboard counts measure activity rather than impact.
Question 28
Within the DORA metrics, what does the change failure rate measure?
- AThe proportion of changes to production that lead to degraded service and need remediation
- BThe number of tickets opened in the service desk each month by end users after each production release
- CThe time a developer spends writing code in a feature branch before a commit
- DThe percentage of servers in the production fleet that run an outdated operating system this quarter
Show answer and explanationHide answer
Correct answer: AChange failure rate is the share of production changes that cause a failure requiring remediation, which measures delivery stability. The other options describe support volume, coding time, or patch status.
Question 29
A platform team wants the lead time for changes measured in a consistent way. What does this DORA metric measure?
- AThe total time the platform team has been operating
- BThe time a developer spends in meetings each week
- CThe time from a code commit to that change running successfully in production
- DThe time taken to answer a support email
Show answer and explanationHide answer
Correct answer: CLead time for changes measures the elapsed time from commit to successful production deployment, which reflects delivery speed. The other options measure unrelated activity.
Question 30
Which measure shows the share of product teams that have adopted the platform's standard paved path?
- APlatform adoption rate
- BNumber of unique IP addresses
- CStorage cost per gigabyte of backup
- DAverage ticket age
Show answer and explanationHide answer
Correct answer: AAdoption rate tracks how many teams use the paved path, which indicates whether the platform delivers value. The other measures do not describe adoption.