Bug 1701450 - Controller prints namespace and label in wrong order
Summary: Controller prints namespace and label in wrong order
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Cloud Compute
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: 4.1.0
Assignee: Jan Chaloupka
QA Contact: Jianwei Hou
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-19 04:45 UTC by Jianwei Hou
Modified: 2019-06-04 10:47 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-04 10:47:47 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0758 0 None None None 2019-06-04 10:47:55 UTC

Description Jianwei Hou 2019-04-19 04:45:55 UTC
Description of problem:
The controller-manager mistook the MachineSet's label for its namespace and vice versa.

I0419 03:39:00.297342       1 controller.go:296] MachineSet "jhou1-95htj-worker-ap-northeast-1c" in namespace "cluster.k8s.io/cluster-name" doesn't specify "openshift-machine-api" label, assuming nil cluster
I0419 03:39:00.298353       1 controller.go:296] MachineSet "jhou1-95htj-worker-ap-northeast-1c" in namespace "cluster.k8s.io/cluster-name" doesn't specify "openshift-machine-api" label, assuming nil cluster

Version-Release number of selected component (if applicable):
4.1.0-0.nightly-2019-04-18-210657

How reproducible:
Always

Steps to Reproduce:
1. oc logs machine-api-controllers-56fdc847d7-fjqgc -c controller-manager -f

Actual results:
This needs to be corrected on both machine and machineSet.

https://github.com/openshift/cluster-api-provider-aws/blob/master/vendor/github.com/openshift/cluster-api/pkg/controller/machine/controller.go#L300

https://github.com/openshift/cluster-api-provider-aws/blob/master/vendor/github.com/openshift/cluster-api/pkg/controller/machineset/controller.go#L296

Expected results:


Additional info:

Comment 1 Jan Chaloupka 2019-04-23 08:15:58 UTC
Upstream PR: https://github.com/kubernetes-sigs/cluster-api/pull/871

Comment 2 Jan Chaloupka 2019-04-23 08:29:22 UTC
Backported PR: https://github.com/openshift/cluster-api/pull/32

Comment 3 Jan Chaloupka 2019-04-25 10:49:29 UTC
Backporting changes to aws-actuator for the machine controller: https://github.com/openshift/cluster-api-provider-aws/pull/204

Comment 5 sunzhaohua 2019-04-26 08:17:48 UTC
verified.

$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.1.0-0.nightly-2019-04-25-121505   True        False         4h47m   Cluster version is 4.1.0-0.nightly-2019-04-25-121505

I0426 08:07:52.575421       1 controller.go:128] Reconciling Machine "zhsun9-pgmk8-worker-us-east-2b-mnf6r"
I0426 08:07:52.575445       1 controller.go:307] Machine "zhsun9-pgmk8-worker-us-east-2b-mnf6r" in namespace "cluster.k8s.io/cluster-name" doesn't specify "openshift-machine-api" label, assuming nil cluster
I0426 08:07:52.575458       1 actuator.go:377] Checking if machine exists
I0426 08:07:52.682385       1 actuator.go:390] Instance exists as "i-0b4008d507322c230"
I0426 08:07:52.682415       1 controller.go:241] Reconciling machine "zhsun9-pgmk8-worker-us-east-2b-mnf6r" triggers idempotent update
I0426 08:07:52.682424       1 actuator.go:303] updating machine
I0426 08:07:52.682570       1 actuator.go:311] obtaining EC2 client for region
I0426 08:07:52.722231       1 actuator.go:328] found 1 instances for machine
I0426 08:07:52.722259       1 actuator.go:347] instance found
I0426 08:07:52.722287       1 actuator.go:474] Updating status
I0426 08:07:52.722344       1 actuator.go:518] finished calculating AWS status
I0426 08:07:52.722437       1 actuator.go:151] status unchanged

Comment 7 errata-xmlrpc 2019-06-04 10:47:47 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-2019:0758


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