Home > Mobile >  How to check the minimum and maximum replica set of Kubernetes pod
How to check the minimum and maximum replica set of Kubernetes pod

Time:07-01

In the yaml file, I have configure the auto-scaling and in this block I've set minimum and maximum replica count, But few deployments are still having 1 pod. I know this might be due to traffic that those deployments having 1 pod might have less traffic. Here's the code of the yaml file:

 autoscaling:
  enabled: true
  minReplicas: 1
  maxReplicas: 3
  targetCPUUtilizationPercentage: 70
  targetMemoryUtilizationPercentage: 80

But, Is there any command through which I can see the limit of my replicas?

CodePudding user response:

You can use:

kubectl get hpa -A -w

with the -A option it gives you all your hpa from all namespaces if you want to specify a namespace, you can use -n option. And the -w argument is for watch so you have a refreshed interface that gives you infos on your hpa ressources.

  • Related