Basic KUBECTL Commands

Basic KUBECTL Commands

The following KubeCTL commands are the most common ones that a client may use

 

Get list of pods

kubectl get pods


Get status of each pod

kubectl describe pod <pod-name>

Get logs for a pod

To look into the actual pod e.g. deployment which is the most important (start here for any troubleshooting on installation)

kubectl logs <pod-name>
 -c <container-name>
  

Show ingress

Used to see what ingress points are configured, hostname configures and ip addresses assigned

kubectl logs <pod-name>
 -c <container-name>
 

To remove a pod

This is used to delete a pod so that it can be recreated

kubectl delete pod <pod-name>
 

To scale a pod

This command can be used to instruct Kubernetes to scale a specific pod if auto scaling is not enabled.

kubectl scale deploy <pod-name>
 --replicas=2  

 


Was this article helpful?
Copyright (C) 2001-2025, Ai Software, LLC d/b/a LumenVox