CKA Free Update With 100% Exam Passing Guarantee [2021]
[Nov-2021] Verified Linux Foundation Exam Dumps with CKA Exam Study Guide
Certification Path
There are no pre-requisites for Linux Foundation-CKA: Certified Kubernetes Administrator exam and the successful completion will give you the title of Certified Kubernetes Administrator
NEW QUESTION 29
Create a deployment as follows:
* Name: nginx-app
* Using container nginx with version 1.11.10-alpine
* The deployment should contain 3 replicas
Next, deploy the application with new version 1.11.13-alpine, by performing a rolling update.
Finally, rollback that update to the previous version 1.11.10-alpine.
Answer:
Explanation:
See the solution below.
Explanation
solution


NEW QUESTION 30
Create a busybox pod and add "sleep 3600" command
Answer:
Explanation:
See the solution below.
Explanation
kubectl run busybox --image=busybox --restart=Never -- /bin/sh -c
"sleep 3600"
NEW QUESTION 31
Create a deployment called webapp with image nginx having 5 replicas in it, put the file in /tmp directory with named webapp.yaml
- A. //Create a file using dry run command
kubectl create deploy --image=nginx --dry-run -o yaml >
/tmp/webapp.yaml
// Now, edit file webapp.yaml and update replicas=5
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: webapp
name: webapp
spec:
replicas: 5
selector:
matchLabels:
app: webapp
template:
metadata:
labels:
app: webapp
spec:
containers:
- image: nginx
name: nginx
Note: Search "deployment" in kubernetes.io site , you will get
the page
https://kubernetes.io/docs/concepts/workloads/controllers/deplo
yment/
// Verify the Deployment
kubectl get deploy webapp --show-labels
// Output the YAML file of the deployment webapp
kubectl get deploy webapp -o yaml - B. //Create a file using dry run command
kubectl create deploy --image=nginx --dry-run -o yaml >
/tmp/webapp.yaml
// Now, edit file webapp.yaml and update replicas=5
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: webapp
name: webapp
spec:
replicas: 5
selector:
matchLabels:
app: webapp
template:
metadata:
labels:
Note: Search "deployment" in kubernetes.io site , you will get
the page
https://kubernetes.io/docs/concepts/workloads/controllers/deplo
yment/
// Verify the Deployment
kubectl get deploy webapp --show-labels
// Output the YAML file of the deployment webapp
kubectl get deploy webapp -o yaml
Answer: A
NEW QUESTION 32
List all the pods sorted by name
Answer:
Explanation:
kubect1 get pods --sort-by=.metadata.name
NEW QUESTION 33
Create 2 nginx image pods in which one of them is labelled with env=prod and another one labelled with env=dev and verify the same.
- A. kubectl run --generator=run-pod/v1 --image=nginx -- labels=env=prod nginx-prod --dry-run -o yaml > nginx-prodpod.yaml Now, edit nginx-prod-pod.yaml file and remove entries like "creationTimestamp: null" "dnsPolicy: ClusterFirst" vim nginx-prod-pod.yaml apiVersion: v1 kind: Pod metadata:
labels:
env: prod
name: nginx-prod
spec:
containers:
- image: nginx
name: nginx-prod
restartPolicy: Always
# kubectl create -f nginx-prod-pod.yaml
kubectl run --generator=run-pod/v1 --image=nginx --
labels=env=dev nginx-dev --dry-run -o yaml > nginx-dev-pod.yaml
apiVersion: v1
kind: Pod
metadata:
labels:
env: dev
name: nginx-dev
spec:
containers:
- image: nginx
name: nginx-dev
restartPolicy: Always
# kubectl create -f nginx-prod-dev.yaml
Verify :
kubectl get po --show-labels
kubectl get po -l env=prod
kubectl get po -l env=dev - B. kubectl run --generator=run-pod/v1 --image=nginx -- labels=env=prod nginx-prod --dry-run -o yaml > nginx-prodpod.yaml Now, edit nginx-prod-pod.yaml file and remove entries like "creationTimestamp: null" "dnsPolicy: ClusterFirst" vim nginx-prod-pod.yaml apiVersion: v1 kind: Pod metadata:
labels:
env: prod
name: nginx-prod
spec:
containers:
- image: nginx
name: nginx-prod
restartPolicy: Always
# kubectl create -f nginx-prod-pod.yaml
kubectl run --generator=run-pod/v1 --image=nginx --
labels=env=dev nginx-dev --dry-run -o yaml > nginx-dev-pod.yaml
apiVersion: v1
kind: Pod
metadata:
- image: nginx
name: nginx-dev
restartPolicy: Always
# kubectl create -f nginx-prod-dev.yaml
Verify :
kubectl get po --show-labels
kubectl get po -l env=dev
Answer: A
NEW QUESTION 34
Create a pod as follows:
Name: non-persistent-redis
container Image: redis
Volume with name: cache-control
Mount path: /data/redis
The pod should launch in the staging be persistent.
Answer:
Explanation:
See the solution below.
Explanation
solution
F:\Work\Data Entry Work\Data Entry\20200827\CKA\13 B.JPG
F:\Work\Data Entry Work\Data Entry\20200827\CKA\13 C.JPG
F:\Work\Data Entry Work\Data Entry\20200827\CKA\13 D.JPG
NEW QUESTION 35
Score: 4%
Task
Scale the deployment presentation
Answer:
Explanation:
See the solution below.
Explanation
Solution:
kubectl get deployment
kubectl scale deployment.apps/presentation --replicas=6
NEW QUESTION 36
Modify "hello-job" and make it run 10 times one after one and 5 times parallelism: 5
- A. kubectl create job hello-job --image=busybox --dry-run -o yaml
-- echo "Hello I am from job" > hello-job.yaml
// edit the yaml file to add completions: 16 and
kubectl create -f hello-job.yaml
YAML File:
apiVersion: batch/v1
kind: Job
metadata:
name: hello-job
spec:
completions: 16
parallelism: 5
template:
metadata:
spec:
containers:
- command:
- echo
- Hello I am from job
image: busybox
name: hello-job
restartPolicy: Never - B. kubectl create job hello-job --image=busybox --dry-run -o yaml
-- echo "Hello I am from job" > hello-job.yaml
// edit the yaml file to add completions: 10 and
kubectl create -f hello-job.yaml
YAML File:
apiVersion: batch/v1
kind: Job
metadata:
name: hello-job
spec:
completions: 10
parallelism: 5
template:
metadata:
spec:
containers:
- command:
- echo
- Hello I am from job
image: busybox
name: hello-job
restartPolicy: Never
Answer: B
NEW QUESTION 37
Given a partially-functioning Kubernetes cluster, identify symptoms of failure on the cluster.
Determine the node, the failing service, and take actions to bring up the failed service and restore the health of the cluster. Ensure that any changes are made permanently.
You can ssh to the relevant I nodes (bk8s-master-0 or bk8s-node-0) using:
[student@node-1] $ ssh <nodename>
You can assume elevated privileges on any node in the cluster with the following command:
[student@nodename] $ | sudo -i
Answer:
Explanation:
See the solution below.
Explanation
solution


NEW QUESTION 38
List the nginx pod with custom columns POD_NAME and POD_STATUS
Answer:
Explanation:
kubectl get po -o=custom-columns="POD_NAME:.metadata.name, POD_STATUS:.status.containerStatuses[].state"
NEW QUESTION 39
Score: 4%
Task
Check to see how many nodes are ready (not including nodes tainted NoSchedule ) and write the number to
/opt/KUSC00402/kusc00402.txt
Answer:
Explanation:
See the solution below.
Explanation
Solution:
kubectl describe nodes | grep ready|wc -l
kubectl describe nodes | grep -i taint | grep -i noschedule |wc -l
echo 3 > /opt/KUSC00402/kusc00402.txt
#
kubectl get node | grep -i ready |wc -l
# taintsnoSchedule
kubectl describe nodes | grep -i taints | grep -i noschedule |wc -l
#
echo 2 > /opt/KUSC00402/kusc00402.txt
NEW QUESTION 40
Create a Job with an image node which prints node version and
verifies there is a pod created for this job
- A. kubectl create job nodeversion --image=node -- node -v
kubectl get job -w
kubectl get pod
YAML File:
apiVersion: batch/v1
kind: Job
metadata:
labels:
job-name: nodeversion
name: nodeversion
spec:
completions: 1
parallelism: 1
selector:
matchLabels:
job-name: nodeversion
template:
metadata:
labels:
job-name: nodeversion
spec:
containers:
- command:
- node
- -v
image: node
imagePullPolicy: Always
name: nodeversion
restartPolicy: Never - B. kubectl create job nodeversion --image=node -- node -v
kubectl get job -w
kubectl get pod
YAML File:
apiVersion: batch/v1
kind: Job
metadata:
labels:
job-name: nodeversion
name: nodeversion
spec:
completions: 1
parallelism: 1
labels:
job-name: nodeversion
spec:
containers:
- command:
- node
- -v
image: node
imagePullPolicy: Always
name: nodeversion
restartPolicy: Never
Answer: A
NEW QUESTION 41
Add a taint to node "worker-2" with effect as "NoSchedule" and
list the node with taint effect as "NoSchedule"
- A. // Add taint to node "worker-2"
kubectl taint nodes worker-2 key=value:NoSchedule
.items[*]}{.metadata.name} {.spec.taints[?(
@.effect=='NoSchedule' )].effect}{\"\n\"}{end}" | awk 'NF==2
{print $0}' - B. // Add taint to node "worker-2"
kubectl taint nodes worker-2 key=value:NoSchedule
// Verify
// Using "custom-coloumns" , you can customize which coloumn to
be printed
kubectl get nodes -o customcolumns=NAME:.metadata.name,TAINTS:.spec.taints --no-headers
// Using jsonpath
kubectl get nodes -o jsonpath="{range
.items[*]}{.metadata.name} {.spec.taints[?(
@.effect=='NoSchedule' )].effect}{\"\n\"}{end}" | awk 'NF==2
{print $0}'
Answer: B
NEW QUESTION 42
Score: 13%
Task
A Kubernetes worker node, named wk8s-node-0 is in state NotReady. Investigate why this is the case, and perform any appropriate steps to bring the node to a Ready state, ensuring that any changes are made permanent.
Answer:
Explanation:
See the solution below.
Explanation
Solution:
sudo -i
systemctl status kubelet
systemctl start kubelet
systemctl enable kubelet
NEW QUESTION 43
To protect your firewall and network from single source denial of service (DoS) attacks that can overwhelm its packet buffer and cause legitimate traffic to drop, you can configure:
- A. PGP (Packet Gateway Protocol)
- B. BGP (Border Gateway Protocol)
- C. PBP (Packet Buffer Protection)
- D. PBP (Protocol Based Protection)
Answer: D
NEW QUESTION 44
......
Authentic Best resources for CKA Online Practice Exam: https://www.topexamcollection.com/CKA-vce-collection.html
CKA Test Engine Practice Exam: https://drive.google.com/open?id=1s_oACeQL9OND7Lci3MFfxCr6TWoVITSf

