Practice Exams:

Linux Foundation KCNA Dumps

EXAM: Kubernetes and Cloud Native Associate
Verified By Experts
Premium Bundle
$40.00
$59.97 $99.97

KCNA Premium Bundle


  • Premium File 333 Questions & Answers
  • Training Course 54 Lectures
  • Study Guide 410 Pages

Linux Foundation KCNA Practice Test 41

Question 400

A university lab accidentally overrides the entrypoint of a known-good container image. Which combined solution and independent check are most directly justified?

  1. Inspect image default command and Pod command or args settings to determine what executable starts in the container. Acceptance evidence: Inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting.
  2. Give each workload an appropriate Kubernetes ServiceAccount and narrow RBAC permissions rather than embedding an administrator kubeconfig in its image. Acceptance evidence: Run a synthetic read-only Pod with a restricted ServiceAccount and verify one permitted API read and one forbidden Secret list.
  3. Build an OCI-compatible image with immutable packaged artifacts and treat running container writable state as ephemeral. Acceptance evidence: Build a test image, run a Pod and recreate it, verifying packaged files remain while an unmounted temporary file disappears.
  4. Choose service boundaries around business capabilities and operational needs, documenting communication cost, ownership and fault tolerance. Acceptance evidence: Model a synthetic two-service checkout dependency and compare rollout independence with failure and latency overhead against a single service.

Explanation

Correct Answer

A:

The situation is that a university lab accidentally overrides the entrypoint of a known-good container image. Inspect image default command and Pod command or args settings to determine what executable starts in the container. Acceptance evidence: Inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting. This pairing is justified because the container runtime starts the configured process, and a crash or early exit can terminate the container regardless of Kubernetes placement.

Incorrect Answers

B:

This action and check address the distinct objective “Differentiate ServiceAccounts from human kubeconfig identities” instead of the stated acceptance requirement. The matching action is to inspect image default command and Pod command or args settings to determine what executable starts in the container. Its confirming test is to inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting.

C:

This action and check address the distinct objective “Distinguish a container image from a running container and its writable layer” instead of the stated acceptance requirement. The matching action is to inspect image default command and Pod command or args settings to determine what executable starts in the container. Its confirming test is to inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting.

D:

This action and check address the distinct objective “Contrast cloud-native microservices with a monolith without treating either as inherently superior” instead of the stated acceptance requirement. The matching action is to inspect image default command and Pod command or args settings to determine what executable starts in the container. Its confirming test is to inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting.

Question 401

A telemetry helper and app container share a scratch buffer in one Pod. Which engineering approach is the most appropriate for this cloud-native case?

  1. Use container runtime namespaces to isolate views of processes and networks while using cgroups to account for and constrain resources.
  2. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement.
  3. Measure request latency and error rates, inspect application logs and correlate trace spans for the affected request before guessing which Pod is slow.
  4. Identify whether the cluster uses kube-proxy or an alternative Service dataplane before diagnosing virtual Service IP forwarding behavior.

Explanation

Correct Answer

B:

Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. This resolves the issue because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal. To verify, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Incorrect Answers

A:

This option addresses the distinct objective “Explain Linux namespaces and cgroups as distinct container isolation mechanisms”, not the immediate requirement. Linux namespaces affect visibility and isolation boundaries, while cgroups organize and limit resource usage; neither automatically supplies a full virtual machine. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

C:

This option addresses the distinct objective “Use metrics, logs and traces together when investigating cross-service latency”, not the immediate requirement. Metrics reveal aggregate trends, logs record events and traces connect operations across services, so each signal answers a different debugging question. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

D:

This option addresses the distinct objective “Understand service proxy implementations without assuming kube-proxy is mandatory”, not the immediate requirement. Kube-proxy can maintain node networking rules for Services, but supported network implementations may replace this function. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Question 402

A telemetry helper and app container share a scratch buffer in one Pod. What infrastructure principle makes the correct treatment effective?

  1. Readiness affects endpoint eligibility while liveness can cause restarts; a startup probe defers other probe checks until initialization succeeds.
  2. Cordon marks a node unschedulable for new ordinary Pods; drain evicts managed workloads when policies and availability permit.
  3. emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.
  4. A deployment pipeline is a trust boundary; signed artifacts and automated policy tests reduce the risk of unreviewed configurations reaching production.

Explanation

Correct Answer

C:

EmptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal. It supports this action: Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. To confirm, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Incorrect Answers

A:

That statement explains the distinct objective “Understand readiness, liveness and startup probes as different signals” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

B:

That statement explains the distinct objective “Use cordon and drain with disruption considerations for planned node maintenance” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

D:

That statement explains the distinct objective “Define secure release governance with staged approvals and policy verification” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Question 403

A telemetry helper and app container share a scratch buffer in one Pod. What verification result would most convincingly distinguish a working solution from a claim?

  1. Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.
  2. Create synthetic invalid quota, unschedulable node and missing-image cases and compare their event reasons and assigned node status.
  3. In a training namespace inspect PID views and a controlled memory limit, noting which mechanism changes identity or resource behavior.
  4. Deploy replicas with hostname anti-affinity and inspect their node placements in a cluster with enough eligible workers.

Explanation

Correct Answer

A:

Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics. This is the relevant test because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

B:

This check would help evaluate the distinct objective “Use describe and Events to distinguish admission, scheduling and execution errors”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

C:

This check would help evaluate the distinct objective “Explain Linux namespaces and cgroups as distinct container isolation mechanisms”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

D:

This check would help evaluate the distinct objective “Use Pod anti-affinity to reduce correlated replica failure”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Question 404

A telemetry helper and app container share a scratch buffer in one Pod. The change review contains this proposal: “Store customer database records only in emptyDir and assume a Deployment rollout preserves them indefinitely.” What risk matters most?

  1. The planned maintenance causes avoidable downtime because no safe application replica remains available.
  2. Cross-namespace calls can fail or resolve a same-named but unrelated local Service.
  3. The deployed artifact grows, may leak build credentials and exposes unnecessary packages.
  4. Replacing the Pod destroys the only copy of business state unless independent durable storage exists.

Explanation

Correct Answer

D:

Replacing the Pod destroys the only copy of business state unless independent durable storage exists. The shortcut creates this risk because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

A:

That outcome concerns the distinct objective “Use cordon and drain with disruption considerations for planned node maintenance”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

B:

That outcome concerns the distinct objective “Verify CoreDNS resolution and namespace-qualified Service names”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

C:

That outcome concerns the distinct objective “Build smaller images with multistage builds and remove unnecessary tooling”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

Question 405

A telemetry helper and app container share a scratch buffer in one Pod. Which implementation together with matching acceptance evidence best meets this case?

  1. Use container runtime namespaces to isolate views of processes and networks while using cgroups to account for and constrain resources. Acceptance evidence: In a training namespace inspect PID views and a controlled memory limit, noting which mechanism changes identity or resource behavior.
  2. Apply appropriate ResourceQuota and LimitRange policy to bound namespace consumption and guide default container resource requests or limits. Acceptance evidence: Create a controlled test namespace with a tiny quota and verify a request exceeding aggregate limits is rejected.
  3. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Acceptance evidence: Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.
  4. Define symptom-based Prometheus alerting rules with sensible durations and route alerts through Alertmanager to the responsible service team. Acceptance evidence: Trigger a controlled error-rate alert, verify its pending/firing transition and confirm the correct team receives a grouped notification.

Explanation

Correct Answer

C:

Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Acceptance evidence: Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics. This pairing is justified because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

A:

This action and check address the distinct objective “Explain Linux namespaces and cgroups as distinct container isolation mechanisms” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

B:

This action and check address the distinct objective “Understand resource quotas and LimitRanges for namespace capacity governance” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

D:

This action and check address the distinct objective “Build meaningful alert rules and route notifications through Alertmanager” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Question 406

A city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Which engineering approach is the most appropriate for this cloud-native case?

  1. Give clients a Service DNS name rather than hardcoding Pod IP addresses that can change when replicas are replaced.
  2. Configure readiness to stop sending Service traffic to an unready Pod, liveness to restart an unhealthy container and startup to allow slow initialization.
  3. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement.
  4. Send cluster changes through the authenticated Kubernetes API and inspect the object returned by the API server rather than changing node processes directly.

Explanation

Correct Answer

C:

The situation is that a city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. This resolves the issue because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal. To verify, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Incorrect Answers

A:

This option addresses the distinct objective “Distinguish Pod IPs from stable Services during rescheduling”, not the immediate requirement. Pods receive network identities that can be ephemeral, while a Service maintains a stable discovery and traffic abstraction over selected endpoints. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

B:

This option addresses the distinct objective “Understand readiness, liveness and startup probes as different signals”, not the immediate requirement. Readiness affects endpoint eligibility while liveness can cause restarts; a startup probe defers other probe checks until initialization succeeds. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

D:

This option addresses the distinct objective “Trace Kubernetes API requests through the kube-apiserver entry point”, not the immediate requirement. The kube-apiserver validates authorized API requests and exposes the declarative resource interface; kubelets and controllers subsequently reconcile the saved desired state. For the stated case, emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Question 407

A city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. What infrastructure principle makes the correct treatment effective?

  1. Image-pull credentials are consumed before the application starts and should not be hardcoded into container layers or app logs.
  2. emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.
  3. A rolling Deployment temporarily creates and removes Pods within its surge and unavailable budgets, but readiness is required for new replicas to count as available.
  4. The scheduler enforces required node label matches in addition to resource and other constraints; labels do not create actual hardware capabilities.

Explanation

Correct Answer

B:

The situation is that a city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. EmptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal. It supports this action: Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. To confirm, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Incorrect Answers

A:

That statement explains the distinct objective “Handle private registry pulls with dedicated credentials instead of embedding secrets in images” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

C:

That statement explains the distinct objective “Configure Deployment rolling updates with availability safeguards” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

D:

That statement explains the distinct objective “Use nodeSelector to place a workload on nodes with required labels” rather than the cause in this case. The deciding mechanism here is that emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Question 408

A city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. What verification result would most convincingly distinguish a working solution from a claim?

  1. Inspect a failed Pod's last terminated reason and check whether an unintended command override prevented the server from starting.
  2. Annotate a Deployment with release notes and verify its Service still selects Pods using explicit app labels.
  3. Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.
  4. Check CNI capabilities, establish a default-deny test policy and verify one allowed and one denied connection.

Explanation

Correct Answer

C:

The situation is that a city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics. This is the relevant test because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

A:

This check would help evaluate the distinct objective “Understand ENTRYPOINT and command overrides when a container exits immediately”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

B:

This check would help evaluate the distinct objective “Use annotations for tool metadata rather than workload selection”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

D:

This check would help evaluate the distinct objective “Recognize NetworkPolicy isolation only when the CNI enforces it”, but not the required result. For this case, write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Question 409

A city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. The change review contains this proposal: “Store customer database records only in emptyDir and assume a Deployment rollout preserves them indefinitely.” What risk matters most?

  1. A project can exhaust shared cluster capacity when declarative metadata is mistaken for enforced admission policy.
  2. Credentials can leak through registries and the binaries cannot be compared as the same tested artifact.
  3. Containers gain broad host exposure and compromise blast radius becomes larger than the application's needs.
  4. Replacing the Pod destroys the only copy of business state unless independent durable storage exists.

Explanation

Correct Answer

D:

The situation is that a city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Replacing the Pod destroys the only copy of business state unless independent durable storage exists. The shortcut creates this risk because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

A:

That outcome concerns the distinct objective “Understand resource quotas and LimitRanges for namespace capacity governance”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

B:

That outcome concerns the distinct objective “Externalize application configuration from an image while protecting secrets”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

C:

That outcome concerns the distinct objective “Run images with least-privilege runtime security contexts”; it is not the most direct consequence of this shortcut. The relevant consequence is that replacing the Pod destroys the only copy of business state unless independent durable storage exists.

Question 410

A city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Which implementation together with matching acceptance evidence best meets this case?

  1. Taint dedicated nodes and grant only intended workloads matching tolerations, combining node affinity when exclusive placement is required. Acceptance evidence: Taint a lab worker dedicated=training:NoSchedule, then compare placement of Pods with and without the toleration.
  2. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Acceptance evidence: Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.
  3. Define post-release checks for readiness, error rate and latency, and revert an unhealthy revision using an approved rollout mechanism. Acceptance evidence: Deploy a synthetic faulty image, monitor request errors and confirm the release controller or operator restores the last known healthy revision.
  4. Use narrowly scoped imagePullSecrets or an approved node identity to authorize the runtime to pull a private image. Acceptance evidence: Deploy a synthetic private image using an approved Secret and confirm unauthorized namespaces cannot reuse a broad registry token.

Explanation

Correct Answer

B:

The situation is that a city records service keeps durable PDF attachments on an emptyDir and loses them during maintenance. Use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Acceptance evidence: Write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics. This pairing is justified because emptyDir is initialized for a Pod and its contents can be shared among containers but do not survive the Pod's removal.

Incorrect Answers

A:

This action and check address the distinct objective “Understand taints and tolerations as repulsion controls” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

C:

This action and check address the distinct objective “Design a release rollback trigger from measurable service signals” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

D:

This action and check address the distinct objective “Handle private registry pulls with dedicated credentials instead of embedding secrets in images” instead of the stated acceptance requirement. The matching action is to use emptyDir for temporary sharing between containers within a Pod, and PVC-backed storage when data must survive Pod replacement. Its confirming test is to write a synthetic temporary file into emptyDir, restart a container and then recreate the Pod to compare lifetime semantics.

Kubernetes and Cloud Native Associate (KCNA) Practice Tests