Linux Foundation CKAD Practice Exam Questions & Answers
Linux Foundation CKAD Exam Details
Key details for this exam, checked against the published exam outline
- Exam Code
- CKAD
- Full Name
- Certified Kubernetes Application Developer (CKAD)
- Issuing Body
- Linux Foundation and Cloud Native Computing Foundation (CNCF)
- Question Format (Our Bank)
- Multiple Choice
- Delivery
- Online proctored, taken from anywhere in the world via PSI
- Eligibility
- No prerequisites required. Candidates must assume working knowledge of container runtimes and microservice architecture.
- Validity
- 2 years from the date of passing the exam
- Full Question Set
- 48 questions Get All Questions
Free CKAD Practice Questions
Each question shows the correct answer and an explanation of why it is right
Question 1 Domain 5 Application Design and Build
SIMULATION

Task:
Update the Pod ckad00018-newpod in the ckad00018 namespace to use a NetworkPolicy allowing the Pod to send and receive traffic only to and from the pods web and db

Solution:


Question 2 Domain 4 Application Deployment
SIMULATION

Set Configuration Context:
[student@node-1] $ | kubectl
Config use-context k8s
Task
You have rolled out a new pod to your infrastructure and now you need to allow it to communicate with the web and storage pods but nothing else. Given the running pod kdsn00201 -newpod edit it to use a network policy that will allow it to send and receive traffic only to and from the web and storage pods.


To allow a pod to send and receive traffic only to and from specific pods, you can use network policies in Kubernetes.
First, you will need to create a network policy that defines the allowed traffic. You can create a network policy yaml file with the following rules:
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: newpod-network-policy
namespace: default
spec:
podSelector:
matchLabels:
app: kdsn00201-newpod
ingress:
- from:
- podSelector:
matchLabels:
app: web
- podSelector:
matchLabels:
app: storage
This policy will only allow incoming traffic to the pod with the label app=kdsn00201-newpod from pods with the label app=web or app=storage. If you have different labels on your web and storage pods please update the matchLabels accordingly.
Once you have created the network policy, you can apply it to the cluster by running the following command:
kubectl apply -f <network-policy-file>.yaml
This will apply the network policy to the cluster, and the newpod will only be able to send and receive traffic to and from the web and storage pods.
Please note that, NetworkPolicy resource is not available by default, you need to enable the NetworkPolicy feature on your Kubernetes cluster. This feature is enabled by default on some clusters and must be explicitly enabled on others. You can check if NetworkPolicy is available by running the command kubectl api-versions | grep networking
Also, you need to ensure that the pods that you want to allow traffic to and from are running on the same namespace.
Question 3 Domain 1 Services and Networking
SIMULATION

Task:
Create a Pod named nginx resources in the existing pod resources namespace.
Specify a single container using nginx:stable image.
Specify a resource request of 300m cpus and 1G1 of memory for the Pod's container.
Solution:




Get the complete CKAD question set
$20$40
Question 4 Domain 2 Application Environment, Configuration and Security
SIMULATION
Context
Anytime a team needs to run a container on Kubernetes they will need to define a pod within which to run the container.
Task
Please complete the following:
* Create a YAML formatted pod manifest
/opt/KDPD00101/podl.yml to create a pod named app1 that runs a container named app1cont using image Ifccncf/arg-output
with these command line arguments: -lines 56 -F
* Create the pod with the kubect1 command using the YAML file created in the previous step
* When the pod is running display summary data about the pod in JSON format using the kubect1 command and redirect the output to a file named /opt/KDPD00101/out1.json
* All of the files you need to work with have been created, empty, for your convenience

Solution:






Question 5 Domain 2 Application Environment, Configuration and Security
SIMULATION

Context
You are asked to prepare a Canary deployment for testing a new application release.
Task:
A Service named krill-Service in the goshark namespace points to 5 pod created by the Deployment named current-krill-deployment

1) Create an identical Deployment named canary-kill-deployment, in the same namespace.
2) Modify the Deployment so that:
-A maximum number of 10 pods run in the goshawk namespace.
-40% of the krill-service 's traffic goes to the canary-krill-deployment pod(s)

Solution:



Question 6 Domain 4 Application Deployment
SIMULATION
You must connect to the correct host . Failure to do so may result in a zero score.
[candidate@base] $ ssh ckad00034c
Task
A Deployment named content-marlin-deployment , running in namespace content-marlin is exposed via Ingress content-marlin-ingress .
The manifest files for the Deployment, Service and Ingress can be found at /home/candidate/content-marlin/.
The Deployment is supposed to be reachable at
ssh ckad00034c
You're debugging an Ingress Service Deployment chain. The fastest way is:
reproduce the error with the right Host header
check Ingress rules (host/path/backend)
check Service (selector/port/targetPort)
check Endpoints (do we have ready pods?)
fix the manifest(s) under /home/candidate/content-marlin/
apply + re-test
Below are the exact commands + the most common fixes for this exact symptom.
1) Reproduce the failing request correctly
Even if DNS isn't set up, you can test with a Host header:
curl -i -H 'Host: content-marlin.local' http://127.0.0.1/content-marlin
If your ingress controller is not on localhost, find the NodePort/LoadBalancer IP. In these labs it's often localhost via a local proxy, but if needed:
kubectl get svc -A | egrep -i 'ingress|nginx'
kubectl get nodes -o wide
(But start with the localhost curl above.)
2) Inspect the provided manifests (this is what you must edit)
cd /home/candidate/content-marlin/
ls -l
sed -n '1,200p' *.yaml
Also view what's currently live in the cluster:
kubectl -n content-marlin get deploy,svc,ingress
kubectl -n content-marlin describe ingress content-marlin-ingress
kubectl -n content-marlin get ingress content-marlin-ingress -o yaml
What to look for in the Ingress:
spec.rules.host should be content-marlin.local
spec.rules.http.paths[].path should match /content-marlin
Backend service name must be your service
Backend service port must match the service port (name or number)
pathType should be Prefix (usually safest)
3) Validate Service Pod wiring (most common real cause)
3.1 Check service selector and ports
kubectl -n content-marlin get svc -o wide
kubectl -n content-marlin describe svc content-marlin-deployment 2>/dev/null || true
kubectl -n content-marlin describe svc
Identify the service that the Ingress points to (from describe ingress).
Check if the Service selector matches pod labels:
kubectl -n content-marlin get pods --show-labels
kubectl -n content-marlin get svc <SERVICE_NAME> -o jsonpath='{.spec.selector}{'\n'}'
3.2 Check endpoints (this tells you instantly if traffic can reach pods)
kubectl -n content-marlin get endpoints
kubectl -n content-marlin get endpoints <SERVICE_NAME> -o wide
If ENDPOINTS is empty Service selector doesn't match Pods OR Pods aren't Ready.
3.3 If endpoints empty, check pod readiness and labels
kubectl -n content-marlin get pods -o wide
kubectl -n content-marlin describe pod
4) Apply the most likely fix patterns
Fix pattern A: Ingress path needs rewrite
If your app serves / but you route /content-marlin, you often need rewrite.
Edit content-marlin-ingress manifest (in /home/candidate/content-marlin/) to include:
path: /content-marlin
pathType: Prefix
annotation: rewrite to / (common for nginx ingress)
Example (typical nginx-ingress):
metadata:
annotations:
nginx.ingress.kubernetes.io/rewrite-target: /
spec:
rules:
- host: content-marlin.local
http:
paths:
- path: /content-marlin
pathType: Prefix
backend:
service:
name: <SERVICE_NAME>
port:
number: 80
If your ingress controller is not nginx, rewrite annotation may differ. But in CKAD labs, it's very often nginx.
Fix pattern B: Ingress points to wrong Service port
If the Ingress backend says port 80 but your Service exposes 8080 (or uses a named port), align them:
Either change Ingress backend port.number
Or change Service spec.ports[].port / targetPort
Fix pattern C: Service selector mismatch (endpoints empty)
If pods have label app=content-marlin but service selector is app=content-marlin-deployment (or vice versa), fix the Service selector to match pod labels.
Service should have:
spec:
selector:
app: <label-that-actually-exists-on-pods>
Fix pattern D: Service targetPort wrong
If container listens on 8080 but service targetPort is 80, fix it:
spec:
ports:
- port: 80
targetPort: 8080
5) Apply the corrected manifests
After editing the YAMLs under /home/candidate/content-marlin/:
kubectl apply -f /home/candidate/content-marlin/
Wait for readiness:
kubectl -n content-marlin rollout status deploy content-marlin-deployment
kubectl -n content-marlin get endpoints
kubectl -n content-marlin describe ingress content-marlin-ingress
6) Re-test the URL
curl -i -H 'Host: content-marlin.local' http://127.0.0.1/content-marlin
If you still get errors, also check ingress controller logs/events quickly:
kubectl -n content-marlin get events --sort-by=.lastTimestamp | tail -n 30
kubectl get pods -A | egrep -i 'ingress|nginx'
The fastest way for you to finish in 1 shot
Run these and paste the output (I'll tell you exactly which line to change and what to change it to):
kubectl -n content-marlin describe ingress content-marlin-ingress
kubectl -n content-marlin get svc -o wide
kubectl -n content-marlin get endpoints -o wide
kubectl -n content-marlin get pods --show-labels
sed -n '1,200p' /home/candidate/content-marlin/*.yaml
But even without pasting, if you follow steps 2--4 above, you'll find the broken link (Ingress rule, Service port, selector, or rewrite) and fix it cleanly.
Question 7 Domain 4 Application Deployment
SIMULATION
You must connect to the correct host . Failure to do so may result in a zero score.
[candidate@base] $ ssh ckad00033
Task
A Dockerfile has been prepared at /home/candidate/build/Dockerfile.
Using the prepared Dockerfile, build a container image with the name macaque and tag 1.2. You may install and use the tool of your choice.
Multiple image builders and tools have been pre-installed in the base system,
including: docker, skopeo, buildah, img , and podman.
Please do not push the built image to a registry, run a container, or otherwise consume it.
Using the tool of your choice, export the built container image in OCI or Docker image format and store it at /home/candidate/macaque-1.2.tar.
Understood --- I'll redo Question 13 without using any (or similar) icons.
ssh ckad00033
This task is only about building and exporting a container image.
You must not push it, run it, or consume it in any way.
You may use any image builder. Below are clean, correct solutions. Use one of them.
Option A: Using Docker
1) Go to the Dockerfile location
cd /home/candidate/build
ls -l Dockerfile
2) Build the image
Image name: macaque
Tag: 1.2
docker build -t macaque:1.2 .
Verify:
docker images | grep macaque
3) Export the image to a tar file
Docker image format is acceptable.
docker save macaque:1.2 -o /home/candidate/macaque-1.2.tar
Verify the file exists:
ls -lh /home/candidate/macaque-1.2.tar
Do not load or run the image.
Option B: Using Podman (rootless alternative)
1) Build the image
cd /home/candidate/build
podman build -t macaque:1.2 .
Verify:
podman images | grep macaque
2) Export the image
podman save macaque:1.2 -o /home/candidate/macaque-1.2.tar
Verify:
ls -lh /home/candidate/macaque-1.2.tar
Option C: Using Buildah (OCI format)
cd /home/candidate/build
buildah bud -t macaque:1.2 .
buildah push macaque:1.2 oci-archive:/home/candidate/macaque-1.2.tar
What the Linux Foundation CKAD Exam Covers
Exam domains verified against the Official Linux Foundation CKAD exam guide, last checked November 2026.
Domain 1 Services and Networking
20%You will demonstrate basic understanding of NetworkPolicies to control traffic flow between pods. You will provide and troubleshoot access to applications via Kubernetes Services, and use Ingress rules to expose applications to external traffic.
Sample question from this domain above Q3
Domain 2 Application Environment, Configuration and Security
25%You will discover and use resources that extend Kubernetes through CRDs and Operators, and demonstrate understanding of authentication, authorization and admission control. You will work with ConfigMaps and Secrets, define resource requests and limits, understand quotas, manage ServiceAccounts and implement Application Security using SecurityContexts and Capabilities.
Domain 3 Application Observability and Maintenance
15%You will understand API deprecations and implement probes and health checks for application reliability. You will use built-in CLI tools to monitor Kubernetes applications, utilize container logs for troubleshooting and debugging, and diagnose issues in Kubernetes environments.
Domain 4 Application Deployment
20%You will use Kubernetes primitives to implement deployment strategies such as blue/green and canary releases. This includes understanding how Deployments work and performing rolling updates, as well as using the Helm package manager to deploy existing packages and Kustomize for template management.
Domain 5 Application Design and Build
20%You will define, build and modify container images for Kubernetes deployments. This includes choosing appropriate workload resources like Deployments, DaemonSets and CronJobs, and understanding multi-container Pod design patterns including sidecar, init and others. You will also work with persistent and ephemeral volumes to support application storage needs.
Sample question from this domain above Q1
CKAD Exam FAQ
Common questions about the exam itself
What background do I need before taking the CKAD exam?
How hard is the CKAD compared to other Kubernetes certifications?
How long should I spend preparing for the CKAD?
What is the passing score for the CKAD exam?
How long is the CKAD exam and what does exam day look like?
How many attempts and retakes do I get for the CKAD exam?
How long is the CKAD certification valid and what does renewal involve?
Which job roles does the CKAD certification target?
What is the relationship between CKAD and other Kubernetes certifications like CKA?
Which exam domains do CKAD candidates typically find most challenging?
Other Linux Foundation Exams
Free practice questions for more Linux Foundation certification exams
