Bug 1694303 - [OCP4 Beta] nodelink-controller and the machine-approver are not working on OpenStack
Summary: [OCP4 Beta] nodelink-controller and the machine-approver are not working on O...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Cloud Compute
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 4.2.0
Assignee: Jan Chaloupka
QA Contact: Jianwei Hou
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-03-30 10:15 UTC by Stuart Auchterlonie
Modified: 2019-10-17 08:41 UTC (History)
5 users (show)

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


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:2922 0 None None None 2019-10-16 06:28:10 UTC

Description Stuart Auchterlonie 2019-03-30 10:15:54 UTC
Description of problem:

Machines objects should be linked to nodes and the csr should approved by the
machine-approver but due to the missing Machine.Status field the created
machines are never linked or approved.

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

OCP4 Beta

How reproducible:

100%

Steps to Reproduce:
1.
2.
3.

Actual results:

without this change there currently two issues on OpenStack:
1.) The cluster will die after some hours because the CSRs are not automatically approved.
2.) The machines that were created via the machine-api are not referenced to the node objects and therefore labels are not synced from the machine definition.


Expected results:

Machines are correctly created via the machine api

Additional info:

This has been identified on OCP4 Beta

Comment 2 Florin Peter 2019-04-07 18:36:28 UTC
upstream PR https://github.com/openshift/cluster-api-provider-openstack/pull/29

Comment 3 Jan Chaloupka 2019-04-08 12:01:44 UTC
This bugzilla ticket is actually about two issues:
1) nodelink controller not linking machines (covered by https://github.com/openshift/cluster-api-provider-openstack/pull/29 as instance IP addresses needs to be reported in a machine status)
2) node approver: machine.Status.NodeRef field needs to be set (https://github.com/openshift/cluster-machine-approver/blob/master/csr_check.go#L102-L107). The field is set by the nodelink controller once a machine and node are linked together (requires IP addresses to be set in the machine status)

So resolving the first issue will unblock the second one.

Switching to POST as https://github.com/openshift/cluster-api-provider-openstack/pull/29 is on review.

Comment 6 Jianwei Hou 2019-08-16 08:22:16 UTC
Verified in 4.2.0-0.nightly-2019-08-15-232721 on OpenStack

Now machines have nodeRef, nodes have machine annotations. 

oc get machines -n openshift-machine-api -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.status.nodeRef.name}{"\n"}'
wjosp0816d-p6jqc-master-0	wjosp0816d-p6jqc-master-0
wjosp0816d-p6jqc-master-1	wjosp0816d-p6jqc-master-1
wjosp0816d-p6jqc-master-2	wjosp0816d-p6jqc-master-2
wjosp0816d-p6jqc-worker-79z2m	wjosp0816d-p6jqc-worker-79z2m
wjosp0816d-p6jqc-worker-g87lp	wjosp0816d-p6jqc-worker-g87lp
wjosp0816d-p6jqc-worker-np44n	wjosp0816d-p6jqc-worker-np44n

oc get nodes
NAME                            STATUS   ROLES    AGE   VERSION
wjosp0816d-p6jqc-master-0       Ready    master   73m   v1.14.0+c4dfe254f
wjosp0816d-p6jqc-master-1       Ready    master   73m   v1.14.0+c4dfe254f
wjosp0816d-p6jqc-master-2       Ready    master   73m   v1.14.0+c4dfe254f
wjosp0816d-p6jqc-worker-79z2m   Ready    worker   67m   v1.14.0+c4dfe254f
wjosp0816d-p6jqc-worker-g87lp   Ready    worker   67m   v1.14.0+c4dfe254f
wjosp0816d-p6jqc-worker-np44n   Ready    worker   62m   v1.14.0+c4dfe254f

oc get nodes -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.metadata.annotations.machine\.openshift\.io\/machine}{"\n"}'
wjosp0816d-p6jqc-master-0	openshift-machine-api/wjosp0816d-p6jqc-master-0
wjosp0816d-p6jqc-master-1	openshift-machine-api/wjosp0816d-p6jqc-master-1
wjosp0816d-p6jqc-master-2	openshift-machine-api/wjosp0816d-p6jqc-master-2
wjosp0816d-p6jqc-worker-79z2m	openshift-machine-api/wjosp0816d-p6jqc-worker-79z2m
wjosp0816d-p6jqc-worker-g87lp	openshift-machine-api/wjosp0816d-p6jqc-worker-g87lp
wjosp0816d-p6jqc-worker-np44n	openshift-machine-api/wjosp0816d-p6jqc-worker-np44n

Comment 7 errata-xmlrpc 2019-10-16 06:27:58 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:2922


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