Bug 1796599

Summary: machine instance-state annotation discrepancy with providerStatus.instanceState
Product: OpenShift Container Platform Reporter: Alberto <agarcial>
Component: Cloud ComputeAssignee: Alberto <agarcial>
Cloud Compute sub component: Other Providers QA Contact: Jianwei Hou <jhou>
Status: CLOSED ERRATA Docs Contact:
Severity: unspecified    
Priority: unspecified CC: vlaad, wking
Version: 4.4   
Target Milestone: ---   
Target Release: 4.4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-05-15 15:57:01 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 Alberto 2020-01-30 18:16:56 UTC
Description of problem:
The instance-state annotation and the providerStatus.instanceState occasionally showing different values [1]. This should never happen as they consume from the same source. This is likely to be an issue on the client failing to patch the status or patching it wrongly. 

[1] https://storage.googleapis.com/origin-ci-test/logs/release-openshift-ocp-installer-e2e-aws-4.4/866/artifacts/e2e-aws/machines.json

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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 4 Jianwei Hou 2020-02-06 08:45:25 UTC
Verified in 4.4.0-0.nightly-2020-02-05-181112. Added regression test for this scenario, this will be covered in future tests.

oc get machines -n openshift-machine-api -o jsonpath='{range .items[*]}{.metadata.annotations}{"\t"}{.status.providerStatus.instanceState}{"\n"}{end}'
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running
map[machine.openshift.io/instance-state:running]	running