Courseiva
Kubernetes FundamentalsmediumDrag & DropObjective-mapped

KCNA Kubernetes Fundamentals Practice Question

Drag and drop the steps to create a Kubernetes Namespace and deploy an application into it into the correct order.

Drag steps to the numbered slots on the right, or tap a step then tap a slot.

Steps
Order
1Step 1
2Step 2
3Step 3
4Step 4
5Step 5

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Create the namespace using 'kubectl create namespace my-namespace', then deploy the application using 'kubectl apply -f deployment.yaml -n my-namespace', then verify the deployment using 'kubectl get pods -n my-namespace'.

First create namespace, then deploy resources specifying that namespace, and verify.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Create the namespace using 'kubectl create namespace my-namespace', then deploy the application using 'kubectl apply -f deployment.yaml -n my-namespace', then verify the deployment using 'kubectl get pods -n my-namespace'.

    Why this is correct

    This is the correct order because the namespace must exist before deploying resources into it, and verification after deployment confirms the application is running in the intended namespace.

  • Deploy the application using 'kubectl apply -f deployment.yaml' without specifying a namespace, then create the namespace using 'kubectl create namespace my-namespace', then verify using 'kubectl get pods'.

    Why it's wrong here

    This is incorrect because deploying first without a namespace puts the application in the default namespace. Creating the namespace afterward does not move the deployment, and verification without a namespace checks the default namespace, not the intended one.

  • Verify the deployment using 'kubectl get pods', then create the namespace using 'kubectl create namespace my-namespace', then deploy the application using 'kubectl apply -f deployment.yaml -n my-namespace'.

    Why it's wrong here

    This is incorrect because verifying before creating the namespace will fail as the namespace does not exist, and the verification step is premature without any resources deployed.

  • Create the namespace using 'kubectl create namespace my-namespace', then verify using 'kubectl get pods -n my-namespace', then deploy the application using 'kubectl apply -f deployment.yaml -n my-namespace'.

    Why it's wrong here

    This is incorrect because verifying after creating the namespace but before deploying the application will show no resources (empty), which does not confirm the deployment; verification should occur after deployment.

Go deeper

Related to this question

About these practice questions

This KCNA question is part of Courseiva's 833-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This KCNA practice question is part of Courseiva's free CNCF certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the KCNA exam.