Bug 1463594 - The 'minReadySeconds' does not work in the deploymentconfig
Summary: The 'minReadySeconds' does not work in the deploymentconfig
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: openshift-controller-manager
Version: 3.6.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.6.z
Assignee: Tomáš Nožička
QA Contact: zhou ying
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-06-21 09:37 UTC by zhou ying
Modified: 2017-10-25 13:02 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
undefined
Clone Of:
Environment:
Last Closed: 2017-10-25 13:02:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:3049 0 normal SHIPPED_LIVE OpenShift Container Platform 3.6, 3.5, and 3.4 bug fix and enhancement update 2017-10-25 15:57:15 UTC

Description zhou ying 2017-06-21 09:37:31 UTC
Description of problem:
During the  DC's MinReadySeconds, the pod  is not ready for DC, but the DC's status:  unavailableReplicas is 0 , and the readyReplicas equals to replicas asap.

Version-Release number of selected component (if applicable):
openshift v3.6.121
kubernetes v1.6.1+5115d708d7
etcd 3.2.0

How reproducible:
always

Steps to Reproduce:
1. Login openshift and create project;
2. Create a DC with file:
apiVersion: v1
kind: DeploymentConfig
metadata:
  name: minreadytest
spec:
  replicas: 2
  minReadySeconds: 50
  selector:
    name: minreadytest
  template:
    metadata:
      labels:
        name: minreadytest
    spec:
      terminationGracePeriodSeconds: 0
      containers:
      - image: "docker.io/centos:centos7"
        imagePullPolicy: IfNotPresent
        name: myapp
        command:
        - /bin/sleep
        - "10000"
3. Check the dc's status.

Actual results:
3. During the  DC's MinReadySeconds, the unavailableReplicas is 0 and  readyReplicas equals to replicas.

Expected results:
3. During the  DC's MinReadySeconds, the pod is not ready for DC, so the unavailableReplicas should equal to replicas, and the readyReplicas should be 0.

Additional info:

Comment 1 Tomáš Nožička 2017-06-29 14:33:52 UTC
https://github.com/openshift/origin/pull/14936

Comment 2 Tomáš Nožička 2017-07-04 10:42:58 UTC
To clarify on what the expected results are:

During MinReadySecond period: AvailableReplicas == 0 && ReadyReplicas==Replicas && UnavailableReplicas==Replicas

Comment 3 zhou ying 2017-07-05 03:17:59 UTC
Couldn't found the latest ami on EC2, will change the status to modified.

Comment 5 zhou ying 2017-07-06 08:02:31 UTC
Confirmed with latest ocp 3.6 version, the issue has fixed:
[root@ip-172-18-7-226 ~]# openshift version
openshift v3.6.135
kubernetes v1.6.1+5115d708d7
etcd 3.2.1

During MinReadySecond period:
oc get dc minreadytest -o yaml
status:
  availableReplicas: 0
  conditions:
  - lastTransitionTime: 2017-07-06T07:59:01Z
    lastUpdateTime: 2017-07-06T07:59:01Z
    message: Deployment config does not have minimum availability.
    status: "False"
    type: Available
  - lastTransitionTime: 2017-07-06T07:59:01Z
    lastUpdateTime: 2017-07-06T07:59:01Z
    message: replication controller "minreadytest-1" is waiting for pod "minreadytest-1-deploy"
      to run
    status: Unknown
    type: Progressing
  details:
    causes:
    - type: ConfigChange
    message: config change
  latestVersion: 1
  observedGeneration: 2
  readyReplicas: 2
  replicas: 2
  unavailableReplicas: 2
  updatedReplicas: 2

After MinReadySecond period:
status:
  availableReplicas: 2
  conditions:
  - lastTransitionTime: 2017-07-06T07:59:59Z
    lastUpdateTime: 2017-07-06T07:59:59Z
    message: Deployment config has minimum availability.
    status: "True"
    type: Available
  - lastTransitionTime: 2017-07-06T08:00:00Z
    lastUpdateTime: 2017-07-06T08:00:00Z
    message: replication controller "minreadytest-1" successfully rolled out
    reason: NewReplicationControllerAvailable
    status: "True"
    type: Progressing
  details:
    causes:
    - type: ConfigChange
    message: config change
  latestVersion: 1
  observedGeneration: 2
  readyReplicas: 2
  replicas: 2
  unavailableReplicas: 0
  updatedReplicas: 2

Comment 7 errata-xmlrpc 2017-10-25 13:02:19 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:3049


Note You need to log in before you can comment on or make changes to this bug.