Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be unavailable on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1805103 - openvswitch2.11 replaces /etc/logrotate.d/openvswitch with the new one after updating RHOSP13 from z9 to z10
Summary: openvswitch2.11 replaces /etc/logrotate.d/openvswitch with the new one after ...
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: documentation
Version: 13.0 (Queens)
Hardware: x86_64
OS: Linux
Target Milestone: async
: 13.0 (Queens)
Assignee: Greg Rakauskas
QA Contact: RHOS Documentation Team
Whiteboard: docs-accepted
Depends On:
Blocks: 1833493 1833494
TreeView+ depends on / blocked
Reported: 2020-02-20 09:21 UTC by Ryo Hayakawa
Modified: 2020-05-08 18:17 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1833493 1833494 (view as bug list)
Last Closed: 2020-05-08 18:12:39 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description Ryo Hayakawa 2020-02-20 09:21:24 UTC
Description of problem:

Updating RHOSP13 from z9 to z11 replaced openvswitch package from openvswitch-2.9.0-117.bz1733374.1.el7ost to openvswitch2.11-2.11.0-26.el7fdp.

After that, the old logrotate config file of openvswitch was moved to /etc/logrotate.d/openvswitch.rpmsave and was replaced to the new one.

I think that /etc/logrotate.d/openvswitch should not be replaced to the new one because both rpms' spec files have the following line in %files section.

  %config(noreplace) %{_sysconfdir}/logrotate.d/openvswitch

I suppose that renaming the package from openvswitch to openvswitch2.11 causes this issue. The yum.log showed lines as follows:

   Jan 30 16:41:27 Installed: openvswitch2.11-2.11.0-26.el7fdp.x86_64
   Jan 30 16:44:12 Erased: openvswitch-2.9.0-117.bz1733374.1.el7ost.x86_64

Is this behavior as expected? Do we have to replace it manually after updating z9 to z10?

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

RHOSP 13 z9 z10


How reproducible:

Steps to Reproduce:

Updating RHOSP13 from z9 to z10 with "openstack overcloud update run"

Actual results:

/etc/logrotate.d/openvswitch was replaced the new one after updating RHOSP from z9 to z10.

Expected results:

/etc/logrotate.d/openvswitch should not be replaced.

Additional info:

Comment 1 Jakub Libosvar 2020-03-10 14:43:09 UTC
I'm switching the component to rpm to see if this is intentional or a bug. I verified both old and new packages have
 %config(noreplace) %{_sysconfdir}/logrotate.d/openvswitch

line in their spec files.

Comment 3 Panu Matilainen 2020-03-20 09:59:40 UTC
I does sound like a bug, but I'm not able to reproduce this when the switch happens within a single transaction as it should. The behavior seen here matches that of 'rpm -e openvswitch; rpm -Uvh openvswitch2.11-*.rpm', ie two different transactions, but the log timestamp snippets suggest a different order.

Can you provide the entire yum.log of the transaction (and preferably the actual command as well) where this happens?

Comment 9 Ryo Hayakawa 2020-04-20 03:02:40 UTC
Hi Panu,

Thank you so much for your reply and an advice related to "yum swap" . 
I ran "yum swap openvswitch rhosp-openvswitch" on my OSP13 in which I had changed /etc/logrotated/openvswitch in advance. After that, I found that it was not changed and the new one was created as "openvswitch.rpmnew" as follows:

  [heat-admin@compute-1 ~]$ rpm -q openvswitch
  [heat-admin@compute-1 ~]$ rpm -qV openvswitch
  S.5....T.  c /etc/logrotate.d/openvswitch
  [heat-admin@compute-1 ~]$ ls -l /etc/logrotate.d/openvswitch*
  -rw-r--r--. 1 root root 691  4月 10 17:02 /etc/logrotate.d/openvswitch
  [heat-admin@compute-1 ~]$ md5sum /etc/logrotate.d/openvswitch*
  fa8a57237dacee67314435c5daba30f0  /etc/logrotate.d/openvswitch
  [heat-admin@compute-1 ~]$ sudo yum swap -y openvswitch rhosp-openvswitch
    Erasing    : openvswitch-2.9.0-117.bz1733374.1.el7ost.x86_64                                                                                              22/22 
    rhosp-openvswitch.noarch 0:2.11-0.6.el7ost                                                                                                                      

  Dependency Installed:
    openvswitch2.11.x86_64 0:2.11.0-35.el7fdp                                                                                                                       

    openvswitch.x86_64 0:2.9.0-117.bz1733374.1.el7ost   
  [heat-admin@compute-1 ~]$ rpm -q openvswitch
  package openvswitch is not installed
  [heat-admin@compute-1 ~]$ rpm -q openvswitch2.11
  [heat-admin@compute-1 ~]$ ls -l /etc/logrotate.d/openvswitch*
  -rw-r--r--. 1 root root 691 Apr 10 17:02 /etc/logrotate.d/openvswitch
  -rw-r--r--. 1 root root 683 Feb 28  2019 /etc/logrotate.d/openvswitch.rpmnew
  [heat-admin@compute-1 ~]$ md5sum /etc/logrotate.d/openvswitch*
  fa8a57237dacee67314435c5daba30f0  /etc/logrotate.d/openvswitch
  8695266fd09b4ad2b0d6962282e60692  /etc/logrotate.d/openvswitch.rpmnew

I think that the above is ideal behavior. If it is possible to run "yum swap" like the above in openstack-tripleo-heat-templates/puppet/services/tripleo-packages.yaml, this issue will be fixed, I think.

I will change the product to OSP13 and the component to openstack-tripleo-heat-templates.


Comment 10 Bernard Cafarelli 2020-04-20 14:56:10 UTC
Recapping some live chat, the current system (in separate transactions) is by design, to prevent dataplane interruptions when updating. This cannot easily be fixed as this is a complex and critical part of the update.

The best course of action here is to document this update limitation, noting to reapply the logrotate configuration after if needed. Updating status accordingly

Comment 13 Bernard Cafarelli 2020-04-23 15:33:43 UTC
To recap:

during updates, if openvswitch major version changes (2.9 to 2.11 for example), customized configuration files for it will be renamed wit .rpmsave extension and default ones installed instead. You will need to reapply these modifications manually afterwards. For example, this includes logrotate configuration /etc/logrotate.d/openvswitch

The reason is that we do not handle the RPM update in a single transaction (which would preserve the modifications), but in separate steps. This is to prevent dataplane interruptions that would be triggered by package update

Comment 15 Greg Rakauskas 2020-05-08 18:12:39 UTC

The following fix added to the RHOSP 13, "Upgrading Red Hat OpenStack Platform" 

   During updates, if the Open vSwitch (OVS) major version changes (for example,
   2.9 to 2.11), director renames any user-customized configuration files with 
   an .rpmsave extension, and installs the default OVS configuration.

   If you want to retain your earlier OVS customizations, you must manually 
   reapply your modifications contained in the renamed files (for example, 
   logrotate configurations in /etc/logrotate.d/openvswitch). This two-step
   update method avoids data plane interruptions that would be triggered by an
   automatic RPM package update.

Customers can now see this content on the Red Hat Cudtomer Portal, here:



Note You need to log in before you can comment on or make changes to this bug.