Bug 1660304
Summary: | [cloud-CA] Update machineautoscaler machineset should first delete the original machineset annotations | ||
---|---|---|---|
Product: | OpenShift Container Platform | Reporter: | sunzhaohua <zhsun> |
Component: | Cloud Compute | Assignee: | Brad Ison <brad.ison> |
Status: | CLOSED ERRATA | QA Contact: | sunzhaohua <zhsun> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 4.1.0 | CC: | jhou |
Target Milestone: | --- | Keywords: | Reopened |
Target Release: | 4.1.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | No Doc Update | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2019-06-04 10:41:16 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
sunzhaohua
2018-12-18 06:32:30 UTC
Work-in-progress PR: https://github.com/openshift/cluster-autoscaler-operator/pull/31 I think this is fixed on master. The last observed target is now recorded in the MachineAutoscaler status, if it's changed the previous target has its annotations removed before the new target is annotated. Verified Create a MachineAutoscaler, then edit it and update the scaleTargetRef to reference a different MachineSet, the previously targeted MachineSet removed its annotations before the new target is annotated. $ oc get clusterversion NAME VERSION AVAILABLE PROGRESSING SINCE STATUS version 4.0.0-0.nightly-2019-01-25-034943 True False 13m Cluster version is 4.0.0-0.nightly-2019-01-25-034943 Create a machineautoscaler to reference machineSet "zhsun-worker-us-east-2a" $ oc get machineautoscaler autoscale-us-east-2a -o yaml spec: maxReplicas: 3 minReplicas: 1 scaleTargetRef: apiVersion: cluster.k8s.io/v1alpha1 kind: MachineSet name: zhsun-worker-us-east-2a status: lastTargetRef: apiVersion: cluster.k8s.io/v1alpha1 kind: MachineSet name: zhsun-worker-us-east-2a $ oc get machineset zhsun-worker-us-east-2a -o yaml annotations: autoscaling.openshift.io/machineautoscaler: openshift-cluster-api/autoscale-us-east-2a sigs.k8s.io/cluster-api-autoscaler-node-group-max-size: "3" sigs.k8s.io/cluster-api-autoscaler-node-group-min-size: "1" Update the machineautoscaler to reference a different MachineSet "zhsun-worker-us-east-2c" $ oc get machineautoscaler autoscale-us-east-2a -o yaml spec: maxReplicas: 3 minReplicas: 1 scaleTargetRef: apiVersion: cluster.k8s.io/v1alpha1 kind: MachineSet name: zhsun-worker-us-east-2c status: lastTargetRef: apiVersion: cluster.k8s.io/v1alpha1 kind: MachineSet name: zhsun-worker-us-east-2c $ oc get machineset zhsun-worker-us-east-2c -o yaml annotations: autoscaling.openshift.io/machineautoscaler: openshift-cluster-api/autoscale-us-east-2c sigs.k8s.io/cluster-api-autoscaler-node-group-max-size: "3" sigs.k8s.io/cluster-api-autoscaler-node-group-min-size: "1" $ oc get machineset zhsun-worker-us-east-2a -o yaml apiVersion: cluster.k8s.io/v1alpha1 kind: MachineSet metadata: labels: sigs.k8s.io/cluster-api-cluster: zhsun sigs.k8s.io/cluster-api-machine-role: worker sigs.k8s.io/cluster-api-machine-type: worker name: zhsun-worker-us-east-2a namespace: openshift-cluster-api spec: replicas: 1 selector: matchLabels: sigs.k8s.io/cluster-api-cluster: zhsun sigs.k8s.io/cluster-api-machineset: zhsun-worker-us-east-2a 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-2019:0758 |