Cloud and Container Basics

A Deployment with replicas: 10 has the rolling update settings maxSurge: 25% and maxUnavailable: 25%. Which of the following correctly gives the upper limit of the total number of Pods and the lower limit of the number of available Pods during an update?

  1. AUpper limit 12, lower limit 8
  2. BUpper limit 13, lower limit 7
  3. CUpper limit 13, lower limit 8
Show answer and explanation

Answer: C. Upper limit 13, lower limit 8

When a percentage is converted into a number of Pods, maxSurge is rounded up and maxUnavailable is rounded down. 10 × 25% = 2.5, so maxSurge becomes 3 and maxUnavailable becomes 2. The upper limit of the total number of Pods is 10 + 3 = 13, and the lower limit of available Pods is 10 − 2 = 8. This rounding helps the update progress while ensuring that the number of available Pods never falls below the specified percentage.

  • A. This rounds maxSurge's 2.5 down. maxSurge is rounded up to 3.
  • B. This rounds maxUnavailable's 2.5 up. maxUnavailable is rounded down to 2.
  • C. Correct. 10 + 3 = 13 and 10 − 2 = 8.
Practice this topic Back to topic

Books on Cloud and Container Basics Ad

As an Amazon Associate I earn from qualifying purchases.

More Cloud and Container Basics questions

  1. In Kubernetes, a Pod gets a different IP address every time it is recreated. Which of the following resources lets other applications connect, through a name and address that do not change, to several Pods selected by labels, with the load spread across them?
  2. In a Kubernetes cluster, HTTPS requests arriving for one host name should be routed to the api Service if the path begins with /api, and to the web Service otherwise. Which of the following resources is suitable for defining this routing rule?
  3. A database password is stored in a Kubernetes Secret. Which of the following correctly describes a Secret?
  4. A web application cannot handle requests for about 60 seconds after starting, while it loads its cache, and returns 503 from /ready during that time. Which of the following correctly describes the effect of adding the settings above to the Pod's container?
  5. In a web application on Kubernetes, the check performed by the liveness probe was made to include whether the application can connect to the database it depends on. Which of the following is the most likely problem with this setting?