How to Manage Your Time in Kubernetes Certification Exams

Jairo Alexander Roldan Agudelo
Globant
Published in
6 min readJul 28, 2023
Photo by Lukas Blazek on Unsplash

If you are planning to take a Kubernetes certification exam such as Certified Kubernetes Application Developer (CKAD) or Certified Kubernetes Administrator (CKA), managing your time is crucial to achieve the best results. It is important not only to have good preparation for your exam but also to have a good strategy for time management to achieve success.

In this article, I am going to give you some tips and tricks to manage your time efficiently when you are taking these kinds of exams. Remember that in these kinds of certification exams, time is against us.

Exams details

These exams are designed to allow you to demonstrate your competencies in a hands-on, command-line environment. Multiple-choice questions are not included in these kinds of exams.

The exams consist of 15–20 performance-based tasks to be solved on a command line and are expected to take approximately two (2) hours to complete. A 66% or above score must be earned to pass the exams. Every question you’ll be asked to answer weighs between 3% to 9%. The weights are indicated in the exam for each question.

Remember that you will be able to skip, move and return to any question during the exam.

Start with the easy questions and move to the hard ones

The first thing you should consider is to start with easy questions (weights between 3 and 4). Like any exam, these kinds of exams have easy questions. Starting with them allows you to optimize your time because it is not probable you will get stuck in easy questions.

Answering all the easy questions first allows you to maximize your points, in other words, to achieve significant progress in the exam without spending all your time on that. Additionally, answering the easy questions first boosts your confidence and that is critical when you take these kinds of exams.

For the second part of your exam, you should answer the medium level questions (weights between 5 and 7). Answering the questions you feel most comfortable with. Remember, do not get stuck. If you feel you are taking too much time answering a question, then you have to skip it and move to the next one. If you have time, you can return to it at the end of the exam and review it.

For the last part of your exam, you should try to answer the hard questions (weights between 8 and 9), including all troubleshooting questions. Do not worry if you do not have enough time to work through all the hard questions. With the progress you have made up to this point, you should be close to having a passing score, so you might need to answer only a few hard questions to pass the exam.

Use Imperative Kubernetes commands

These exams have a hands-on, command-line environment. For that reason, the use of imperative commands is crucial to manage your time efficiently. Imperative commands in Kubernetes are those that directly instruct the system to perform specific actions. When you use an imperative command, you are explicitly stating what operations should be performed. For example, to create a deployment, you can use this command:

kubectl create deployment [deploy-name] --image=nginx --replicas=3 --port=8081

For this command, you can see there are some parameters to configure a new deployment:

  • image: The name of the image used to create the deployment.
  • replicas: The number of replicas to be created.
  • port: The port that the containers expose.
  • deploy-name: The Deployment name.

If you are wondering how much time you will save using imperative commands, you can see the following manifest required to create a deployment with the same parameters as the previous command:

apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: my-deploy
name: my-deploy
spec:
replicas: 3
selector:
matchLabels:
app: my-deploy
strategy: {}
template:
metadata:
labels:
app: my-deploy
spec:
containers:
- image: nginx
name: nginx
ports:
- containerPort: 8081
resources: {}
status: {}

You can infer from the above code that using imperative commands over manifests is faster than writing a YAML file from scratch. Additionally, you could have problems with format and spaces when you write YAML files, spending even more time.

If you forgot which parameters you can use in the Kubernetes create commands, you can leverage the built-in documentation and use the following command to obtain this information:

kubectl create [resource-type] --help

Where resource type is the resource you want to create, for example:

kubectl create deployment --help

As a result, you can get this information, including examples:

Image 1: Information for deployment when help is used.

The resources you can create using imperative commands could be obtained using this command:

kubectl create --help

This command will list all the available resources:

Image 2: List of Kubernetes resources that can be created using imperative commands.

If you check closely the previous image, you realize that services cannot be created using the create command. To create services, you have to use the expose command:

kubectl expose deployment [deployment-name] --port=80 --target-port=8000

This command creates a service using a deployment, configuring the exposed port as 80.

However, when you use the expose command to create a service, you cannot parametrize the service type. By default, the service is created as ClusterIP type. However, it is possible to change the type using the following command:

kubectl edit service [service-name]

In this case, the manifest of the service is loaded in the editor, and you can change the ClusterIP type as desired:

Image 3: An example of a YAML manifest for a Kubernetes Service with ClusterIP type.

Keep in mind that you can create services using expose from different resources such as replica sets, deployments, pods, replication controllers, or even other services.

Finally, you should use short alias to save time when you write imperative Kubernetes commands. Many Kubernetes resources have short aliases that you can use. In the following table, you can find some of them:

Table 1: Kuberntes resources alias

Simplify your YAML files

Do not create your YAML files from scratch. If you are required to create YAML files in the exam, you should always generate them using the –dry-run option with client value and output in YAML format. For example, you are required to create a manifest file for a deployment and save it so that you can use the following command:

kubectl create deploy my-deploy --image=nginx --port=8081 --dry-run=client -o yaml

As a result, you can get this manifest:

Image 4: An example of a YAML manifest for a Kubernetes Deployment.

Also, if you need to create the YAML file, you can include the operator “>>” and the name of the file to do so:

kubectl create deploy my-deploy --image=nginx --port=8081 --dry-run=client -o yaml >> deploy.yml

Conclusions

  • Mastering imperative commands is essential for saving valuable time during Kubernetes Certified exams. To excel in the exams, you must diligently familiarize yourself with these commands, practice using them consistently, and integrate them into your workflow.
  • Optimizing your time during Kubernetes Certified exams can be achieved by starting with the easier questions. By tackling the straightforward questions first, you reduce the likelihood of getting stuck and allow yourself more time to focus on the more challenging ones.
  • Save valuable time during these exams by avoiding writing YAML files from scratch. The process consumes significant time that you cannot afford. Instead, use the –dry-run option to generate YAML templates, allowing you to concentrate on answering the questions efficiently.

Time management is crucial when you take Kubernetes certification exams. With the strategy described in this article, you should be able to manage your time efficiently and have spare time to review any question you feel is not right, so you can get an even higher score. Good Luck!

References

--

--