Luna Lovegood:
number of replicas in deployment == number of pods
Is this true?
Luna Lovegood:
number of replicas in deployment == number of pods
Is this true?
gurunath choukekar:
Yes
Luna Lovegood:
Deployment ensures that only a certain number of Pods are down while they are being updated. By default, it ensures that at least 75% of the desired number of Pods are up (25% max unavailable).
Deployment also ensures that only a certain number of Pods are created above the desired number of Pods. By default, it ensures that at most 125% of the desired number of Pods are up (25% max surge).
For example, if you look at the above Deployment closely, you will see that it first creates a new Pod, then deletes an old Pod, and creates another new one. It does not kill old Pods until a sufficient number of new Pods have come up, and does not create new Pods until a sufficient number of old Pods have been killed. It makes sure that at least 3 Pods are available and that at max 4 Pods in total are available. In case of a Deployment with 4 replicas, the number of Pods would be between 3 and 5.
https://kubernetes.io/docs/concepts/workloads/controllers/deployment/
This helps
Aneek Bera:
yes,
Aneek Bera:
but in case of pod disruption budget the concept works bit differently
Luna Lovegood:
thanks