Real CKA Exam PDF Test Engine Practice Test Questions [Q17-Q37]

Share

Real CKA Exam PDF Test Engine Practice Test Questions

Linux Foundation CKA Real 2022 Braindumps Mock Exam Dumps


Average Salary of Linux Foundation-CKA: Certified Kubernetes Administrator Exam Certified Professionals

The average salary of a AI-900: Microsoft Azure AI Fundamentals Exam Outlook and Modules Exam Certified Expert in:

  • England - 84,784 POUND
  • India - 11,74,223 INR
  • United State - 145,112 USD
  • Europe - 105,1100 EURO

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 17
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 namespace and the volume must not be persistent.

Answer:

Explanation:
See the solution below.
Explanation
solution


 

NEW QUESTION 18
Which one is the correct configuration?

  • A. @Panorama
  • B. &Panorama
  • C. $Panorama
  • D. #Panorama

Answer: C

 

NEW QUESTION 19
Create and configure the service front-end-service so it's accessible through NodePort and routes to the existing pod named front-end.

Answer:

Explanation:
See the solution below.
Explanation
solution
F:\Work\Data Entry Work\Data Entry\20200827\CKA\8 B.JPG

 

NEW QUESTION 20
Check the image version in pod without the describe command

Answer:

Explanation:
See the solution below.
Explanation
kubectl get po nginx -o
jsonpath='{.spec.containers[].image}{"\n"}'

 

NEW QUESTION 21
List "nginx-dev" and "nginx-prod" pod and delete those pods

  • A. kubect1 get pods -o wide
    kubectl delete po "nginx-dev" kubectl delete po "nginx-prod"
  • B. kubect1 get pods -o wide
    kubectl delete po "nginx-dev" kubectl delete po "nginx-prod"

Answer: B

 

NEW QUESTION 22
List the nginx pod with custom columns POD_NAME and POD_STATUS

Answer:

Explanation:
See the solution below.
Explanation
kubectl get po -o=custom-columns="POD_NAME:.metadata.name,
POD_STATUS:.status.containerStatuses[].state"

 

NEW QUESTION 23
Create a deployment as follows:
* Name: nginx-random
* Exposed via a service nginx-random
* Ensure that the service & pod are accessible via their respective DNS records
* The container(s) within any pod(s) running as a part of this deployment should use the nginx Image Next, use the utility nslookup to look up the DNS records of the service & pod and write the output to
/opt/KUNW00601/service.dns and /opt/KUNW00601/pod.dns respectively.

Answer:

Explanation:
See the solution below.
Explanation
Solution:


 

NEW QUESTION 24
Create a deployment spec file thatwill:
* Launch 7 replicas of thenginxImage with the labelapp_runtime_stage=dev
* deployment name:kual00201
Save a copy of this spec file to/opt/KUAL00201/spec_deployment.yaml
(or/opt/KUAL00201/spec_deployment.json).
When you are done, clean up (delete)any new Kubernetes API object thatyou produced during this task.

Answer:

Explanation:
See the solution below.
Explanation
solution

 

NEW QUESTION 25
Create a pod that echo "hello world" and then exists. Have the pod deleted automatically when it's completed

Answer:

Explanation:
See the solution below.
Explanation
kubectl run busybox --image=busybox -it --rm --restart=Never --
/bin/sh -c 'echo hello world'
kubectl get po # You shouldn't see pod with the name "busybox"

 

NEW QUESTION 26
A bootstrap USB flash drive has been prepared using a Windows workstation to load the initial configuration of a Palo Alto Networks firewall that was previously being used in a lab. The USB flash drive was formatted using file system FAT32 and the initial configuration is stored in a file named init-cfg.txt. The firewall is currently running PAN-OS 10.0 and using a lab config. The contents of init-cgf.txt in the USB flash drive are as follows:
type=dhcp-client
Ip-address=
default-gateway=
netmask=
Ipv6-address=
Ipv6-default-gateway=
hostname=Ca-FW-DC1
panorama-server=10.5.107.20
panorama-server-2=10.5.107.21
tplname=FINANCE_TG4
dgname=finance_dg
dns-primary=10.5.6.6
dns-secondary=10.5.6.7
op-command-modes-multi-vsys.jumbo-frame
dhcp-send-hostname=yes
dhcp-send-client-id=yes
dhcp-accept-server-hostname=yes
dhcp-accept-server-domain=yes
The USB flash drive has been inserted in the firewalls' USB port, and the firewall has been restarted using command> request restart system Upon restart, the firewall fails to begin the bootstrapping process. The failure is caused because:

  • A. Firewall must be in factory default state or have all private data deleted for bootstrapping
  • B. The bootstrap xml file is a required file, but it is missing
  • C. The USB must be formatted using the exi3 file system, FAT32 is
  • D. PAN-OS version must be 9.1 x at a minimum, but the firewall is running 10.0x
  • E. The hostname is a required parameter, but it is missing in init-cfg.txt

Answer: C

 

NEW QUESTION 27
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 thestagingnamespace and the volumemust notbe persistent.

Answer:

Explanation:
See the solution below.
Explanation
solution


 

NEW QUESTION 28
Create a busybox pod which executes this command sleep 3600 with the service account admin and verify

  • A. kubectl run busybox --image=busybox --restart=Always --dry-run
    -o yaml -- /bin/sh -c "sleep 3600" > busybox.yml
    // Edit busybox.yaml file
    apiVersion: v1
    kind: Pod
    metadata:
    creationTimestamp: null
    labels:
    run: busybox
    name: busybox
    spec:
    serviceAccountName: admin
    containers:
    - args:
    - /bin/sh
    - -c
    - sleep 3600
    image: busybox
    name: busybox
    restartPolicy: Always
    // verify
    K kubectl describe po busybox
  • B. kubectl run busybox --image=busybox --restart=Always --dry-run
    -o yaml -- /bin/sh -c "sleep 3600" > busybox.yml
    // Edit busybox.yaml file
    apiVersion: v1
    kind: Pod
    metadata:
    creationTimestamp: null
    labels:
    run: busybox
    name: busybox
    spec:
    serviceAccountName: admin
    containers:
    - args:
    - /bin/sh
    - -c
    - sleep 3800
    image: busybox
    name: busybox
    restartPolicy: Always
    // verify
    K kubectl describe po busybox

Answer: A

 

NEW QUESTION 29
Create a persistent volume with name app-data, of capacity 2Gi and access mode ReadWriteMany. The type of volume is hostPath and its location is /srv/app-data.

Answer:

Explanation:
See the solution below.
Explanation
solution
Persistent Volume
A persistent volume is a piece of storage in a Kubernetes cluster. PersistentVolumes are a cluster-level resource like nodes, which don't belong to any namespace. It is provisioned by the administrator and has a particular file size. This way, a developer deploying their app on Kubernetes need not know the underlying infrastructure. When the developer needs a certain amount of persistent storage for their application, the system administrator configures the cluster so that they consume the PersistentVolume provisioned in an easy way.
Creating Persistent Volume
kind: PersistentVolumeapiVersion: v1metadata: name: spec: capacity: # defines the capacity of PV we are creating storage: 2Gi #the amount of storage we are tying to claim accessModes: # defines the rights of the volume we are creating - ReadWriteMany " # path to which we are creating the volume Challenge Create a Persistent Volume named ReadWriteMany, storage classname shared, 2Gi of storage capacity and the host path

2. Save the file and create the persistent volume.
Image for post

3. View the persistent volume.

Our persistent volume status is available meaning it is available and it has not been mounted yet. This status will change when we mount the persistentVolume to a persistentVolumeClaim.
PersistentVolumeClaim
In a real ecosystem, a system admin will create the PersistentVolume then a developer will create a PersistentVolumeClaim which will be referenced in a pod. A PersistentVolumeClaim is created by specifying the minimum size and the access mode they require from the persistentVolume.
Challenge
Create a Persistent Volume Claim that requests the Persistent Volume we had created above. The claim should request 2Gi. Ensure that the Persistent Volume Claim has the same storageClassName as the persistentVolume you had previously created.
kind: PersistentVolumeapiVersion: v1metadata: name:
spec:
accessModes: - ReadWriteMany
requests: storage: 2Gi
storageClassName: shared
2. Save and create the pvc
njerry191@cloudshell:~ (extreme-clone-2654111)$ kubect1 create -f app-data.yaml persistentvolumeclaim/app-data created
3. View the pvc
Image for post

4. Let's see what has changed in the pv we had initially created.
Image for post

Our status has now changed from available to bound.
5. Create a new pod named myapp with image nginx that will be used to Mount the Persistent Volume Claim with the path /var/app/config.
Mounting a Claim
apiVersion: v1kind: Podmetadata: creationTimestamp: null name: app-dataspec: volumes: - name:congigpvc persistenVolumeClaim: claimName: app-data containers: - image: nginx name: app volumeMounts: - mountPath: "/srv/app-data " name: configpvc

 

NEW QUESTION 30
A bootstrap USB flash drive has been prepared using a Linux workstation to load the initial configuration of a Palo Alto Networks firewall. The USB flash drive was formatted using file system ntfs and the initial configuration is stored in a file named init-cfg.txt.
The contents of Init-cfg.txt in the USB flash drive are as follows:
type=static
ip-address=10.5.107.19
default-gateway=10.5.107.1
netmask=255.255.255.0
Ipv6-address=2001:400:100::1/64
ipv6-default-gateway=2001:400:100::2
hostname=Ca-FW-DC1
panorama-server=10.5.107.20
panorama-server-2=10.5.107.21
tplname=FINANCE TG4
dgname=finance_dg
dns-primary=10.5.6.6
op-command-modes multi-vsys.jumbo-frame
dhcp-send-hostname=no
dhcp-send-client-id=no
dhcp-accept-server-hostname=no
dhcp-accept-server-domain=no
The USB flash drive has been inserted in the firewalls' USB port, and the firewall has been powered on.Upon boot, the firewall fails to begin the bootstrapping process. The failure is caused because:

  • A. The USB must be formatted using the ext4 file system
  • B. nit-cfg bit is an incorrect filename the correct filename should be init-ofg.xml
  • C. There must be commas between the parameter names and their values instead of the equal symbols
  • D. The bootstrap.xml file is a required file, but it is missing
  • E. The USB drive has been formatted with an unsupported file system

Answer: A

 

NEW QUESTION 31
Create a redis pod named "test-redis" and exec into that pod and create a file named "test-file.txt" with the text 'This is called the test file' in the path /data/redis and open another tab and exec again with the same pod and verifies file exist in the same path.

  • A. vim test-redis.yaml
    apiVersion: v1
    kind: Pod
    metadata:
    name: test-redis
    spec:
    containers:
    - name: redis
    image: redis
    ports:
    - containerPort: 6379
    volumeMounts:
    - mountPath: /data/redis
    name: redis-storage
    volumes:
    kubectl exec -it test-redis /bin/sh
    cd /data/redis
    echo 'This is called the test file' > file.txt
    //open another tab
    kubectl exec -it test-redis /bin/sh
    cat /data/redis/file.txt
  • B. vim test-redis.yaml
    apiVersion: v1
    kind: Pod
    metadata:
    name: test-redis
    spec:
    containers:
    - name: redis
    image: redis
    ports:
    - containerPort: 6379
    volumeMounts:
    - mountPath: /data/redis
    name: redis-storage
    volumes:
    - name: redis-storage
    emptyDir: {}
    kubectl apply -f redis-pod-vol.yaml
    // first terminal
    kubectl exec -it test-redis /bin/sh
    cd /data/redis
    echo 'This is called the test file' > file.txt
    //open another tab
    kubectl exec -it test-redis /bin/sh
    cat /data/redis/file.txt

Answer: B

 

NEW QUESTION 32
Create an nginx pod and set an env value as 'var1=val1'. Check the env value existence within the pod

  • A. kubectl run nginx --image=nginx --restart=Never --env=var1=val1
    # then
    kubectl exec -it nginx -- env
    # or
    kubectl exec -it nginx -- sh -c 'echo $var1'
    # or
    kubectl describe po nginx | grep val1
    # or
    kubectl run nginx --restart=Never --image=nginx --env=var1=val1
    -it --rm - env
  • B. kubectl run nginx --image=nginx --restart=Never --env=var1=val1
    # then
    kubectl exec -it nginx -- env
    # or
    kubectl run nginx --restart=Never --image=nginx --env=var1=val1
    -it --rm -- env

Answer: A

 

NEW QUESTION 33
Create a deployment as follows:
Name: nginx-app
Using container nginx with version 1.11.10-alpine
The deployment should contain
Next, deploy the application with new version , by performing a rolling update.
Finally, rollback that update to the previous version

Answer:

Explanation:
See the solution below.
Explanation
solution
F:\Work\Data Entry Work\Data Entry\20200827\CKA\7 B.JPG

F:\Work\Data Entry Work\Data Entry\20200827\CKA\7 C.JPG

F:\Work\Data Entry Work\Data Entry\20200827\CKA\7 D.JPG

 

NEW QUESTION 34
Given a partially-functioningKubernetes cluster, identifysymptoms of failure on the cluster.
Determine the node, the failingservice, and take actions to bring upthe failed service and restore thehealth of the cluster. Ensure that anychanges are made permanently.
You cansshto the relevant Inodes (bk8s-master-0orbk8s-node-0) using:
[student@node-1] $ ssh<nodename>
You can assume elevatedprivileges on any node in thecluster with the followingcommand:
[student@nodename] $ | sudo -i

Answer:

Explanation:
See the solution below.
Explanation
solution


 

NEW QUESTION 35
How can an administrator configure the NGFW to automatically quarantine a device using Global Protect?

  • A. There is no native auto-quarantine feature so a custom script would need to be leveraged.
  • B. by adding the device's Host ID to a quarantine list and configure GlobalProtect to prevent users from connecting to the GlobalProtect gateway from a quarantined device.
  • C. by using security policies, log forwarding profiles, and log settings.
  • D. by exporting the list of quarantined devices to a pdf or csv file by selecting PDF/CSV at the bottom of the Device Quarantine page and leveraging the appropriate XSOAR playbook.

Answer: B

 

NEW QUESTION 36
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 37
......

Prepare For The CKA Question Papers In Advance: https://www.validtorrent.com/CKA-valid-exam-torrent.html

Released Linux Foundation CKA Updated Questions PDF: https://drive.google.com/open?id=1IBDfzH6r3Jr7V0gTg5EPzRCGMpEtdNIf