Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1394177 - Update to 6.2.4 does relabel /var/lib/pulp
Update to 6.2.4 does relabel /var/lib/pulp
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Pulp (Show other bugs)
6.2.4
x86_64 Linux
urgent Severity urgent (vote)
: 6.2.7
: Unused
Assigned To: satellite6-bugs
Peter Ondrejka
: Triaged
Depends On:
Blocks: 1316897 1405527
  Show dependency treegraph
 
Reported: 2016-11-11 05:37 EST by Simon Reber
Modified: 2018-09-19 11:11 EDT (History)
18 users (show)

See Also:
Fixed In Version: pulp-2.8.7.4-2
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1405527 (view as bug list)
Environment:
Last Closed: 2017-01-26 05:45:12 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 2765791 None None None 2016-11-14 05:29 EST
Pulp Redmine 2424 High CLOSED - CURRENTRELEASE restorecon runs unecessarily for all 2.10+ upgrades 2016-12-02 11:01 EST
Pulp Redmine 2436 Urgent CLOSED - CURRENTRELEASE pulp-selinux RPM fails to run restorecon statements post install 2016-12-02 11:01 EST
Red Hat Product Errata RHBA-2017:0197 normal SHIPPED_LIVE Satellite 6.2.7 Async Bug Release 2017-01-26 10:38:38 EST

  None (edit)
Description Simon Reber 2016-11-11 05:37:12 EST
Description of problem:

Customer noticed that update to Satellite 6.2.4 does relabel `/var/lib/pulp` which can take a while for a productive environment that has lots of products synced.

Checking this in `pulp.spec` I found:

 955 %pre selinux
 956 # Record old version so we can limit which restorecon statement are executed later
 957 test -e %{_localstatedir}/lib/rpm-state/%{name} || mkdir -p %{_localstatedir}/lib/rpm-state/%{name}
 958 oldversion=$(semodule -l | grep pulp-server)
 959 echo ${oldversion:12} > %{_localstatedir}/lib/rpm-state/%{name}/old-version

I guess the problem is, that we no longer show the SELinux module version in Red Hat Enterprise Linux 7.3. See https://bugzilla.redhat.com/show_bug.cgi?id=1392573 for more details

Because of this, I think the check is failing and thus initiate relabel.sh

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

 - foreman-1.11.0.54-1.el7sat.noarch
 - pulp-server-2.8.7.3-1.el7sat.noarch
 - candlepin-0.9.54.14-1.el7.noarch

How reproducible:

Always

Steps to Reproduce:
1. Install Satellite 6.2 on Red Hat Enterprise Linux 7.2
2. Update Red Hat Enterprise Linux to 7.3
3. Update to Stellite 6.2.4 and check if pulp does a relabel

Actual results:

Does a relabel even if that is likely not required

Expected results:

Should not do a relabel respectively the test in `pulp.spec` should be adjusted according to https://bugzilla.redhat.com/show_bug.cgi?id=1392573

Additional info:

See https://bugzilla.redhat.com/show_bug.cgi?id=1392573 for more details
Comment 4 Brian Bouterse 2016-11-15 08:20:50 EST
I can see how this is a problem, and I believe upstream is affected. I've filed the upstream bug as 2424. We'll be tracking the issue on the related bug.
Comment 7 Brian Bouterse 2016-11-15 14:43:01 EST
The restorecon operation is I/O bound not CPU or memory bound. I expect the runtime to be proportional to the amount of data in /var/lib/pulp/ and the speed of the filesystem. So solid state will be very fast, spinning local disks normal, and NFS mounted filesystem will likely take a long time.
Comment 8 pulp-infra@redhat.com 2016-11-15 16:31:22 EST
The Pulp upstream bug status is at ASSIGNED. Updating the external tracker on this bug.
Comment 9 pulp-infra@redhat.com 2016-11-15 16:31:26 EST
The Pulp upstream bug priority is at High. Updating the external tracker on this bug.
Comment 10 pulp-infra@redhat.com 2016-11-15 20:31:47 EST
The Pulp upstream bug status is at POST. Updating the external tracker on this bug.
Comment 11 Brian Bouterse 2016-11-17 18:04:50 EST
The upstream issue is at modified. This should cherry pick cleanly onto 2.8.7+
Comment 12 pulp-infra@redhat.com 2016-11-17 18:31:29 EST
The Pulp upstream bug status is at MODIFIED. Updating the external tracker on this bug.
Comment 13 pulp-infra@redhat.com 2016-11-21 17:31:18 EST
The Pulp upstream bug status is at ON_QA. Updating the external tracker on this bug.
Comment 14 pulp-infra@redhat.com 2016-11-23 09:31:25 EST
The Pulp upstream bug status is at VERIFIED. Updating the external tracker on this bug.
Comment 16 pulp-infra@redhat.com 2016-11-23 14:01:10 EST
The Pulp upstream bug status is at MODIFIED. Updating the external tracker on this bug.
Comment 17 pulp-infra@redhat.com 2016-11-23 14:01:15 EST
The Pulp upstream bug priority is at Urgent. Updating the external tracker on this bug.
Comment 18 pulp-infra@redhat.com 2016-11-23 22:31:29 EST
The Pulp upstream bug status is at ON_QA. Updating the external tracker on this bug.
Comment 19 pulp-infra@redhat.com 2016-11-28 14:00:59 EST
The Pulp upstream bug status is at VERIFIED. Updating the external tracker on this bug.
Comment 20 pulp-infra@redhat.com 2016-12-02 11:01:12 EST
The Pulp upstream bug status is at CLOSED - CURRENTRELEASE. Updating the external tracker on this bug.
Comment 21 pulp-infra@redhat.com 2016-12-02 11:01:19 EST
The Pulp upstream bug status is at CLOSED - CURRENTRELEASE. Updating the external tracker on this bug.
Comment 22 Julio Entrena Perez 2016-12-07 05:31:18 EST
Since we are aligning this to 6.2.6, is there any workaround that will allow customers to avoid the relabelling if/when they upgrade to 6.2.5?
Comment 24 pulp-infra@redhat.com 2017-01-11 06:02:02 EST
All upstream Pulp bugs are at MODIFIED+. Moving this bug to POST.
Comment 26 Peter Ondrejka 2017-01-18 12:18:38 EST
Verified in Satellite 6.2.7 snap 2 using steps from comment #23, /var/lib/pulp is no longer relabeled upon upgrade.
Comment 28 errata-xmlrpc 2017-01-26 05:45:12 EST
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.

https://access.redhat.com/errata/RHBA-2017:0197

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