Some tasks are still using yum instead of dnf making the command always fail.

Bug #1888821 reported by Sofer Athlan-Guyot
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Committed
Critical
Sofer Athlan-Guyot

Bug Description

Hi,

I bumped into this in another review:

2020-07-23 21:05:42 | "cmd": "yum check-upgrade openvswitch | awk '/openvswitch/{print}'\n",

2020-07-23 21:05:42 | "delta": "0:00:00.007338",

2020-07-23 21:05:42 | "end": "2020-07-23 21:05:41.999441",

2020-07-23 21:05:42 | "failed_when_result": false,

2020-07-23 21:05:42 | "invocation": {

2020-07-23 21:05:42 | "module_args": {

2020-07-23 21:05:42 | "_raw_params": "yum check-upgrade openvswitch | awk '/openvswitch/{print}'\n",

2020-07-23 21:05:42 | "_uses_shell": true,

2020-07-23 21:05:42 | "argv": null,

2020-07-23 21:05:42 | "chdir": null,

2020-07-23 21:05:42 | "creates": null,

2020-07-23 21:05:42 | "executable": null,

2020-07-23 21:05:42 | "removes": null,

2020-07-23 21:05:42 | "stdin": null,

2020-07-23 21:05:42 | "stdin_add_newline": true,

2020-07-23 21:05:42 | "strip_empty_ends": true,

2020-07-23 21:05:42 | "warn": true

2020-07-23 21:05:42 | }

2020-07-23 21:05:42 | },

2020-07-23 21:05:42 | "rc": 0,

2020-07-23 21:05:42 | "start": "2020-07-23 21:05:41.992103",

2020-07-23 21:05:42 | "stderr": "/bin/sh: yum: command not found",

2020-07-23 21:05:42 | "stderr_lines": [

2020-07-23 21:05:42 | "/bin/sh: yum: command not found"

2020-07-23 21:05:42 | ],

2020-07-23 21:05:42 | "stdout": "",

2020-07-23 21:05:42 | "stdout_lines": []

2020-07-23 21:05:42 | }

from https://zuul.opendev.org/t/openstack/build/47e7eae5cc06440889dd697587e76a3a/log/logs/undercloud/home/zuul/overcloud_update_run_Controller.log#4041-4068

Doing a quick grep we still have a bunch of yum command around.

We should strive to use the ansible_pkg_mgr ansible variable to get the right tool (dnf, yum) as I suspect that some of those command associated with "failed_when" false may be silently failing since a long time.

wes hayutin (weshayutin)
tags: added: upgrade
Changed in tripleo:
milestone: victoria-1 → victoria-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to tripleo-heat-templates (stable/ussuri)

Related fix proposed to branch: stable/ussuri
Review: https://review.opendev.org/743947

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to tripleo-heat-templates (stable/train)

Related fix proposed to branch: stable/train
Review: https://review.opendev.org/743949

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to tripleo-heat-templates (master)

Reviewed: https://review.opendev.org/742632
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=8ca2b598cbee79177f36448b421692b4cd9c8c8d
Submitter: Zuul
Branch: master

commit 8ca2b598cbee79177f36448b421692b4cd9c8c8d
Author: Sofer Athlan-Guyot <email address hidden>
Date: Thu Jul 23 12:17:31 2020 +0200

    Add openvswitch special treatment to update too.

    Openvswitch package update can be disruptive during update too. So we
    factor out the code used for upgrade to re-use for update and
    undercloud update.

    We also fix a issue where yum/yumdownloader is not available anymore.
    This cause the special treatment to not happen anymore what not matter
    what.

    Instead of duplicating the ansible sequence, this has been ported to a
    ansible module that replicate the action defined in the templates.

    We also make sure to not try to restart the openvswitch service if
    nothing has been changed during the ovs upgrade task. This cover two
    cases. First, it's an optimization, if nothing has been done, we
    don't need to check the service. Second, and most importantly, if ovs
    isn't installed (this can happen on some minimal installation) then we
    don't try to restart the non-existent service.

    We keep the tasks at step 3 that make sure again that the openvswitch
    service is started. This is a failsafe and as such we ignore any
    error there. This also support the overcloud-minimal type of
    installation.

    Depends-On: https://review.opendev.org/742968
    Change-Id: I4fde50e353ab7b2e6b03d963f585f6abe35ca32d
    Closes-Bug: #1888651
    Related-Bug: #1888821

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to tripleo-heat-templates (stable/ussuri)

Reviewed: https://review.opendev.org/743947
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=c2b828fbb8b1e9f085ecbd6d5abd085733f3b7cb
Submitter: Zuul
Branch: stable/ussuri

commit c2b828fbb8b1e9f085ecbd6d5abd085733f3b7cb
Author: Sofer Athlan-Guyot <email address hidden>
Date: Thu Jul 23 12:17:31 2020 +0200

    Add openvswitch special treatment to update too.

    Openvswitch package update can be disruptive during update too. So we
    factor out the code used for upgrade to re-use for update and
    undercloud update.

    We also fix a issue where yum/yumdownloader is not available anymore.
    This cause the special treatment to not happen anymore what not matter
    what.

    Instead of duplicating the ansible sequence, this has been ported to a
    ansible module that replicate the action defined in the templates.

    We also make sure to not try to restart the openvswitch service if
    nothing has been changed during the ovs upgrade task. This cover two
    cases. First, it's an optimization, if nothing has been done, we
    don't need to check the service. Second, and most importantly, if ovs
    isn't installed (this can happen on some minimal installation) then we
    don't try to restart the non-existent service.

    We keep the tasks at step 3 that make sure again that the openvswitch
    service is started. This is a failsafe and as such we ignore any
    error there. This also support the overcloud-minimal type of
    installation.

    Depends-On: https://review.opendev.org/743837
    Change-Id: I4fde50e353ab7b2e6b03d963f585f6abe35ca32d
    Closes-Bug: #1888651
    Related-Bug: #1888821
    (cherry picked from commit 8ca2b598cbee79177f36448b421692b4cd9c8c8d)

tags: added: in-stable-ussuri
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to tripleo-heat-templates (stable/train)

Reviewed: https://review.opendev.org/743949
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=ed65866d438b16698bc2b8aff8bbf3b0610ddd71
Submitter: Zuul
Branch: stable/train

commit ed65866d438b16698bc2b8aff8bbf3b0610ddd71
Author: Sofer Athlan-Guyot <email address hidden>
Date: Thu Jul 23 12:17:31 2020 +0200

    Add openvswitch special treatment to update too.

    Openvswitch package update can be disruptive during update too. So we
    factor out the code used for upgrade to re-use for update and
    undercloud update.

    We also fix a issue where yum/yumdownloader is not available anymore.
    This cause the special treatment to not happen anymore what not matter
    what.

    Instead of duplicating the ansible sequence, this has been ported to a
    ansible module that replicate the action defined in the templates.

    We also make sure to not try to restart the openvswitch service if
    nothing has been changed during the ovs upgrade task. This cover two
    cases. First, it's an optimization, if nothing has been done, we
    don't need to check the service. Second, and most importantly, if ovs
    isn't installed (this can happen on some minimal installation) then we
    don't try to restart the non-existent service.

    We keep the tasks at step 3 that make sure again that the openvswitch
    service is started. This is a failsafe and as such we ignore any
    error there. This also support the overcloud-minimal type of
    installation.

    Depends-On: https://review.opendev.org/743838
    Change-Id: I4fde50e353ab7b2e6b03d963f585f6abe35ca32d
    Closes-Bug: #1888651
    Related-Bug: #1888821
    (cherry picked from commit 8ca2b598cbee79177f36448b421692b4cd9c8c8d)
    (cherry picked from commit c2b828fbb8b1e9f085ecbd6d5abd085733f3b7cb)

tags: added: in-stable-train
Revision history for this message
Kevin Carter (kevin-carter) wrote :

there's been no interaction on this bug for some time and all noted reviews have merged. marking fix committed.

Changed in tripleo:
status: Triaged → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.