Bug 1713263

Summary: "--force" did not take effect when work with "--to-latest" when do upgrade with cli
Product: OpenShift Container Platform Reporter: liujia <jiajliu>
Component: Cluster Version OperatorAssignee: Abhinav Dahiya <adahiya>
Status: CLOSED ERRATA QA Contact: liujia <jiajliu>
Severity: low Docs Contact:
Priority: medium    
Version: 4.1.0CC: aos-bugs, jokerman, mmccomas
Target Milestone: ---   
Target Release: 4.3.0   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-01-23 11:04:11 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:

Description liujia 2019-05-23 09:44:33 UTC
Description of problem:

[root@preserve-jliu-worker 20190523_15261]# ./oc adm upgrade --to-latest=true --force
Updating to latest version 4.1.0-0.nightly-2019-05-22-050858

[root@preserve-jliu-worker 20190523_15261]# ./oc adm upgrade
info: An upgrade is in progress. Unable to apply 4.1.0-0.nightly-2019-05-22-050858: the image may not be safe to use


VERSION                           IMAGE
4.1.0-0.nightly-2019-05-21-060354 registry.svc.ci.openshift.org/ocp/release@sha256:65236cc32eb9972f661aecd7da4f3bfba61414c0c26730ea85549378c6c08d3e
4.1.0-0.nightly-2019-05-22-190823 registry.svc.ci.openshift.org/ocp/release@sha256:bd0af072c542d6a4aa614151a6caf9f69a197b33e0f57dc180ea795a7baf0159
4.1.0-0.nightly-2019-05-22-050858 registry.svc.ci.openshift.org/ocp/release@sha256:29e03d18fb7fe375bc5d103f22df3343fc40843a6acfbb52b785b7f3aee3921f

Version-Release number of the following components:

How reproducible:

Steps to Reproduce:
1. Run "# ./oc adm upgrade --to-latest=true --force" to upgrade current cluster due to signed image issue.

Actual results:
Upgrade can not proceed with "--to-latest --force" by force.

Expected results:
Upgrade command "--to-latest --force" should work by force.

Additional info:
Please attach logs from ansible-playbook with the -vvv flag

Comment 1 liujia 2019-07-05 06:56:32 UTC
Change the priority to "M" due to qe can not test "--to-latest" item with "--force". But "--force" is a must for prerelease nightly build.

Comment 2 Abhinav Dahiya 2019-08-16 13:51:26 UTC
Fixes need to be merged to 4.2 first, we will open a backport BZ if this was needed for 4.1 too.

Comment 4 liujia 2019-11-19 06:26:18 UTC
Version: 4.3.0-0.nightly-2019-11-18-175710
# ./oc version
Client Version: openshift-clients-4.3.0-201910250623-62-g1cfe371d

# ./oc adm upgrade
Cluster version is 4.3.0-0.nightly-2019-11-18-123403


VERSION                           IMAGE
4.3.0-0.nightly-2019-11-18-175710 registry.svc.ci.openshift.org/ocp/release@sha256:ca53dc5affac0979fc2fa5480dab43c4b77ee216221fbbcef99eea601d7ab785
4.3.0-0.nightly-2019-11-18-201425 registry.svc.ci.openshift.org/ocp/release@sha256:69d87efc70d108c2292c258d9d7108a4e432de74083a857a34ddd6531b654e92

# ./oc adm upgrade --to-latest=true --force
Updating to latest version 4.3.0-0.nightly-2019-11-18-201425

# ./oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.3.0-0.nightly-2019-11-18-201425   True        False         5m3s    Cluster version is 4.3.0-0.nightly-2019-11-18-201425

Comment 6 errata-xmlrpc 2020-01-23 11:04:11 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.