Some things which worked for me: • Having some alias which is needed most of th . . .

Aroup Goldar Dhruba:
Some things which worked for me:

• Having some alias which is needed most of the time:

alias k='kubectl'
alias kn='k config set-context --current --namespace'

alias kg='k get'
alias kgp='kg po'
alias kd='k describe'
alias kdr='k -o yaml --dry-run=client'

alias kap='k apply -f'
alias krm='k delete --force --grace-period=0'

echo 'set sw=2 ts=2 expandtab ai ic' > ~/.vimrc

• Finished the kodekloud course two times. Did all of the labs. Before starting some of the labs, I try to write the aforementioned aliases from scratch in the nodepad, to see if I can write them properly.
• I did the LFS258 from linux foundation, they had some exercises in the end. But if you do kodekloud, you already know most of the things.
• Before the exam, do the killer shell if you have them on the Linux foundation or bought them. If you go through all of the problems twice - you would gain confidence. The problems are really hard, it took me around 3:30-4:00 hour to get through 25 of them.
For the exam:

• If you have multiple monitor - use them. I did the exam on the laptop and I was having the hard time keeping two tabs side by side. In the end it worked out well.
• Use imperative command when you can. Use the cheatsheet to get the commands. Apart from cheat sheet, this link is a gem, not talked about very often: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands|Reference Doc>
• Use kubectl create -h to get helps in creating resources. kubectl create service nodeport -h will show you the how to create the resource.
• Switch clusters using the command, get back to the base after you have made the operations in master and worker node. Check the namespaces in which you are running the command.
• Always use dry run first to see if the configurations are correct.
• Before deleting any resources - backup the yaml file. This is really important. If you delete those, and you can’t recreate it - they might be lost forever.

Tilak Mangisetty:
@Aroup Goldar Dhruba thanks for the tips

Tilak Mangisetty:
How often it is required to create yaml file

Aroup Goldar Dhruba:
You don’t have to create from scratch. You can always copy and edit from the kubernetes doc.

A quick run on kubectl create -h shows what you can create by imperative commands:

Available Commands:
  clusterrole         Create a ClusterRole.
  clusterrolebinding  Create a ClusterRoleBinding for a particular ClusterRole
  configmap           Create a configmap from a local file, directory or literal value
  cronjob             Create a cronjob with the specified name.
  deployment          Create a deployment with the specified name.
  job                 Create a job with the specified name.
  namespace           Create a namespace with the specified name
  poddisruptionbudget Create a pod disruption budget with the specified name.
  priorityclass       Create a priorityclass with the specified name.
  quota               Create a quota with the specified name.
  role                Create a role with single rule.
  rolebinding         Create a RoleBinding for a particular Role or ClusterRole
  secret              Create a secret using specified subcommand
  service             Create a service using specified subcommand.
  serviceaccount      Create a service account with the specified name

You can create them by imperative commands and dry run to get the yaml file and then edit.

It’s barely needed to write yaml files from scratch. Thanks.