Modify update script to cover package configs updating

Bug #1620301 reported by Alexander Kurenyshev
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
High
Ivan Berezovskiy
Mitaka
Fix Released
High
Ivan Berezovskiy

Bug Description

Some time ago the updating script was introduced [1]. It replaced old way when `fuel-bootstrap` was called.

We (fuel-qa team) had switched all our updating procedures to this new script. Our customers will use this script also.

When we updated the master node with this script we faced a problem with packets fuel-agent and fuel-bootstrap-cli and it's updated config which didn't update an old config on the master.
At the fuel-agent package spec we found `%config(noreplace) %{_sysconfdir}/fuel-bootstrap-cli/fuel_bootstrap_cli.yaml`. This means that we will not update that file by default way.

The result of the update script is:
+ echo 'Master node update is <successfully complete> (log: /var/log/puppet/update_master_node.log )'
Master node update is <successfully complete> (log: /var/log/puppet/update_master_node.log )
+ exit 0
But in fact we have an updated package fuel-bootstrap-cli and an outdated config `fuel_bootstrap_cli.yaml`
And additional work with rpm -U was needed to replace old config:
rpm -e fuel-bootstrap-cli
rpm -Uhv --force fuel-bootstrap-cli-9.0.0-1.mos289.noarch.rpm

So I suggest to add some checks and warning to the output to avoid misunderstanding of update status.
Or add some interactive questions asked what user should do with old configs if new ones are provided.

[1] https://github.com/openstack/fuel-library/commit/66229fdf424971cf20f95e34d4873f92da38387b

tags: added: swarm-blocker
Changed in fuel:
status: New → Confirmed
Revision history for this message
Ivan Berezovskiy (iberezovskiy) wrote :

Fuel-sustaining team, is it safe to always update fuel_bootstrap_cli.yaml config? If not, what is the solution you can suggest here?

Changed in fuel:
assignee: MOS Puppet Team (mos-puppet) → Fuel Sustaining (fuel-sustaining-team)
Revision history for this message
Maksim Malchuk (mmalchuk) wrote :

Definitely safe if you start deployment/puppet/fuel/examples/host.pp manifest after the upgrade package, it should merge data and recreate the yaml-file with actual information.

tags: added: area-library
Changed in fuel:
assignee: Fuel Sustaining (fuel-sustaining-team) → Ivan Berezovskiy (iberezovskiy)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-agent (master)

Fix proposed to branch: master
Review: https://review.openstack.org/366662

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-agent (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/366663

Changed in fuel:
assignee: Ivan Berezovskiy (iberezovskiy) → Maksim Malchuk (mmalchuk)
Changed in fuel:
assignee: Maksim Malchuk (mmalchuk) → Ivan Berezovskiy (iberezovskiy)
milestone: 9.1 → 10.0
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-agent (master)

Reviewed: https://review.openstack.org/366662
Committed: https://git.openstack.org/cgit/openstack/fuel-agent/commit/?id=8234a29665cac34ec34dd962a0117544d2bd1e9c
Submitter: Jenkins
Branch: master

commit 8234a29665cac34ec34dd962a0117544d2bd1e9c
Author: iberezovskiy <email address hidden>
Date: Wed Sep 7 13:28:32 2016 +0300

    Replace fuel_bootstrap_cli.yaml on package installation/update

    Config fuel_bootstrap_cli.yaml should be updated along with
    fuel-bootstrap-cli package update. This config will be modified
    later when master node will be configured: http://goo.gl/W36lG4

    Change-Id: I4861e429a121b45aa864ec63fe164a03cf2ed74b
    Closes-bug: #1620301

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-agent (stable/mitaka)

Reviewed: https://review.openstack.org/366663
Committed: https://git.openstack.org/cgit/openstack/fuel-agent/commit/?id=c15adf0ce81833178c4a8b19a9c2fe831047120e
Submitter: Jenkins
Branch: stable/mitaka

commit c15adf0ce81833178c4a8b19a9c2fe831047120e
Author: iberezovskiy <email address hidden>
Date: Wed Sep 7 13:28:32 2016 +0300

    Replace fuel_bootstrap_cli.yaml on package installation/update

    Config fuel_bootstrap_cli.yaml should be updated along with
    fuel-bootstrap-cli package update. This config will be modified
    later when master node will be configured: http://goo.gl/W36lG4

    Change-Id: I4861e429a121b45aa864ec63fe164a03cf2ed74b
    Closes-bug: #1620301

Changed in fuel:
status: Fix Committed → Fix Released
Revision history for this message
Nastya Urlapova (aurlapova) wrote :

@Timur, please specify a version what was used for verification!

Changed in fuel:
status: Fix Released → Fix Committed
Revision history for this message
Alexander Kurenyshev (akurenyshev) wrote :

From test on the #299 snapshot [1]:
Updating : fuel-bootstrap-cli-9.0.0-1.mos291.noarch 26/74
warning: /etc/fuel-bootstrap-cli/fuel_bootstrap_cli.yaml saved as /etc/fuel-bootstrap-cli/fuel_bootstrap_cli.yaml.rpmsave

This means our script makes change on configuration -> everything works fine now

[1] https://product-ci.infra.mirantis.net/job/9.x.system_test.ubuntu.ha_neutron_tun/70/consoleFull

Changed in fuel:
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/fuel-agent 10.0.0rc1

This issue was fixed in the openstack/fuel-agent 10.0.0rc1 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/fuel-agent 10.0.0

This issue was fixed in the openstack/fuel-agent 10.0.0 release.

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.