Skip to content

When upgrading using "mas upgrade" there is no way to re-launch the command if the environment took more time than expected to complete some task. #1938

@guillemmayolramis1

Description

@guillemmayolramis1

MAS CLI version

ibmmas/cli:17.2.0

CLI function used

upgrade

What happened?

Environment:

  • OCP 4.16
  • SNO
  • MAS Manage, IOT and Monitor.
  1. I ran mas upgrade
    `
    [ibmmas/cli:17.2.0]mascli$ mas upgrade

IBM Maximo Application Suite Admin CLI v17.2.0
Powered by https://github.com/ibm-mas/ansible-devops/ and https://tekton.dev/

  1. Set Target OpenShift Cluster
    Already connected to OCP Cluster:
    https://console-openshift-console.apps.ibm.maximo

Proceed with this cluster? [y/n] y

  1. Instance Selection
    Select a MAS instance to upgrade from the list below:
  • maxdemo1 v9.0.16

Enter MAS instance ID: maxdemo1

  1. License Terms
    To continue with the upgrade, you must accept the license terms:
  1. Review Settings
    Instance ID ..................... maxdemo1
    Current MAS Channel ............. 9.0.x
    Next MAS Channel ................ 9.1.x
    Skip Pre-Upgrade Checks ......... False

Proceed with these settings? [y/n] y

  1. Launch Upgrade
    ✅️ OpenShift Pipelines Operator is installed and ready to use
    ✅️ Namespace is ready (mas-maxdemo1-pipelines)
    ✅️ Latest Tekton definitions are installed (v17.2.0)
    ✅️ PipelineRun for maxdemo1 upgrade submitted

View progress:
https://XXXXXXXXX/k8s/ns/mas-maxdemo1-pipelines/tekton.dev~v1beta1~PipelineRun/maxdemo1-upgrade-251201-0917

[ibmmas/cli:17.2.0]mascli$
`
Pipeline Tasks

  1. waitfor/approval. PASS
  2. pre-upgrade-check. PASS
  3. core/upgrade. PASS
  4. core-verify.PASS
  5. app-manage-upgrade. FAIL
    due to
    FAILED - RETRYING: [localhost]: Check that all workspace CRs are healthy (manage only) (1 retries left).
  6. sync-upgrade. PASS

So, it failed due to the long time that two manage builds took. But finally Manage came up fine on 9.1.5.

The bug is that there is no way to re-lauch the "mas upgrade" again to fix and continue upgrading the rest of the components.

Either if I run "mas upgrade" from CLI or re/run the existing pipeline in OpenShift console, the process attempts to upgrade to the next level. In this case from 9.1.x to 9.2.x-feature. Lucky me having IOT still on 9.0.x did not allow the upgrade proceed.

core-upgrade tasks returned

`
TASK [ibm.mas_devops.suite_upgrade : iot : Check that upgrade is supported from current application] ***
fatal: [localhost]: FAILED! => {
"assertion": "check_app.id in compatibility_matrix[mas_channel]",
"changed": false,
"evaluated_to": false,
"msg": "Unable to upgrade to 9.2.x-feature because ibm-mas-iot is installed and is not compatible with this release."
}

`
I attempted to set the MAS_CHANNEL env in cli container and run "mas upgrade" but still attempts to upgrade to 9.2.x-feature

export MAS_CHANNEL=9.1.x.

So, there MUST be a way to select the MAS CHANNEL for "mas Upgrade" to allow partial upgrades be able to get completed.

Relevant log output

core-upgrade tasks returned

`
TASK [ibm.mas_devops.suite_upgrade : iot : Check that upgrade is supported from current application] ***
fatal: [localhost]: FAILED! => {
    "assertion": "check_app.id in compatibility_matrix[mas_channel]",
    "changed": false,
    "evaluated_to": false,
    "msg": "Unable to upgrade to 9.2.x-feature because ibm-mas-iot is installed and is not compatible with this release."
}

Metadata

Metadata

Labels

Bug ReportSomething isn't workingHigh PriorityHigh priority issue to be addressed asap

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions