Bug 1578422

Summary: [backport] HPA replica count calculation fixes
Product: OpenShift Container Platform Reporter: Eric Rich <erich>
Component: NodeAssignee: Seth Jennings <sjenning>
Status: CLOSED ERRATA QA Contact: weiwei jiang <wjiang>
Severity: high Docs Contact:
Priority: unspecified    
Version: 3.7.1CC: aos-bugs, jcantril, jokerman, mmccomas, sjenning
Target Milestone: ---   
Target Release: 3.7.z   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Fixes an issue where HPA will scale above maxReplicas in some situations
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-06-07 08:40:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Eric Rich 2018-05-15 14:41:47 UTC
Description of problem: 

Commit: https://github.com/kubernetes/kubernetes/commit/27297ea76136cf6bf16ae2d840152497c6937e0f 
PR: https://github.com/openshift/origin/pull/18216

Version-Release number of selected component (if applicable): 3.7.23

Additional info:

Comment 5 weiwei jiang 2018-05-29 05:10:54 UTC
Checked with 

# oc version 
oc v3.7.51
kubernetes v1.7.6+a08f5eeb62
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://ip-172-18-5-186.ec2.internal:8443
openshift v3.7.51
kubernetes v1.7.6+a08f5eeb62

And the issue can not be reproduced.

# oc get hpa -w
NAME      REFERENCE                TARGETS    MINPODS   MAXPODS   REPLICAS   AGE
hello     DeploymentConfig/hello   0% / 80%   1         5         1          1m
hello     DeploymentConfig/hello   59% / 80%   1         5         1         3m
hello     DeploymentConfig/hello   546% / 80%   1         5         1         3m
hello     DeploymentConfig/hello   1230% / 80%   1         5         4         4m
hello     DeploymentConfig/hello   697% / 80%   1         5         4         4m
hello     DeploymentConfig/hello   376% / 80%   1         5         4         5m
hello     DeploymentConfig/hello   375% / 80%   1         5         4         5m
hello     DeploymentConfig/hello   390% / 80%   1         5         4         6m
hello     DeploymentConfig/hello   375% / 80%   1         5         4         6m
hello     DeploymentConfig/hello   371% / 80%   1         5         4         7m
hello     DeploymentConfig/hello   375% / 80%   1         5         5         7m
hello     DeploymentConfig/hello   299% / 80%   1         5         5         8m
hello     DeploymentConfig/hello   309% / 80%   1         5         5         8m
hello     DeploymentConfig/hello   304% / 80%   1         5         5         9m
hello     DeploymentConfig/hello   299% / 80%   1         5         5         9m
hello     DeploymentConfig/hello   305% / 80%   1         5         5         10m
hello     DeploymentConfig/hello   298% / 80%   1         5         5         10m
hello     DeploymentConfig/hello   307% / 80%   1         5         5         11m
hello     DeploymentConfig/hello   313% / 80%   1         5         5         11m
hello     DeploymentConfig/hello   304% / 80%   1         5         5         12m
hello     DeploymentConfig/hello   302% / 80%   1         5         5         12m
hello     DeploymentConfig/hello   97% / 80%   1         5         5         13m
hello     DeploymentConfig/hello   0% / 80%   1         5         5         13m
hello     DeploymentConfig/hello   0% / 80%   1         5         1         14m

Comment 7 errata-xmlrpc 2018-06-07 08:40:56 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-2018:1798