Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1085389

Summary: internal test suite fails when rebuilding the source RPM
Product: Red Hat Enterprise Linux 7 Reporter: Milos Malik <mmalik>
Component: aclAssignee: Kamil Dudka <kdudka>
Status: CLOSED ERRATA QA Contact: Eva Mrakova <emrakova>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.0CC: emrakova, kdudka
Target Milestone: rcKeywords: EasyFix, Patch
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: acl-2.2.51-14.el7 Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-10 13:13:40 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
complete output of rpmbuild --rebuild acl-... none

Description Milos Malik 2014-04-08 13:37:45 UTC
Description of problem:
 * few unexpected Permission denied messages appears during the rebuild of the source RPM which is the reason why the rebuild process fails

Version-Release number of selected component (if applicable):
acl-2.2.51-12.el7.src.rpm

How reproducible:
always (all architectures, does not matter if SELinux is in enforcing or permissive mode)

Steps to Reproduce:
1. download acl-2.2.51-12.el7.src.rpm
2. rpmbuild --rebuild acl-2.2.51-12.el7.src.rpm
3. search for errors in the rpmbuild output

Actual results:
101 commands (97 passed, 4 failed)
gmake[1]: *** [root/permissions.test] Error 4
gmake[1]: Leaving directory `/root/rpmbuild/BUILD/acl-2.2.51/test'
make: *** [root-tests] Error 2
+ exit 2
error: Bad exit status from /var/tmp/rpm-tmp.DlWgHZ (%check)

Expected results:
 * internal test suite passes

Comment 1 Milos Malik 2014-04-08 13:40:52 UTC
Created attachment 884085 [details]
complete output of rpmbuild --rebuild acl-...

Comment 2 Milos Malik 2014-04-08 18:57:35 UTC
# gpasswd -a daemon bin
Adding user daemon to group bin
#

Now the internal test suite passes.

Comment 3 Kamil Dudka 2014-04-14 12:00:20 UTC
Thanks for the analysis and sorry for the late reply on this, I was on vacation last week.  The bug only happens if rpmbuild is run by the root user.  mock runs it under a non-privileged user, so the bug does not affect production builds.

Comment 6 Kamil Dudka 2016-05-19 09:24:04 UTC
(In reply to Milos Malik from comment #2)
> # gpasswd -a daemon bin
> Adding user daemon to group bin
> #
> 
> Now the internal test suite passes.

I am afraid that above is the actual fix.  It cannot be done from the acl package because the %check section of acl.spec is not supposed to alter the system out of the build root.  You simply need to run the command yourself.

The upstream test (test/root/permissions.test) is clearly documented to have such a requirement:

    This script tests if file permissions are properly checked with and
    without ACLs. The script must be run as root to allow switching users.
    The following users are required. They must be a member in the groups
    listed in parentheses.

        bin (bin)
        daemon (bin, daemon)

The only fix I can implement would be to skip the test in case the requirement is not met (which is not on default RHEL-7).

Comment 10 Fedora Update System 2017-06-22 07:25:54 UTC
acl-2.2.52-13.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-c71743bffc

Comment 11 Fedora Update System 2017-06-22 07:26:06 UTC
acl-2.2.52-15.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-2028746562

Comment 12 Fedora Update System 2017-06-23 03:28:49 UTC
acl-2.2.52-13.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-c71743bffc

Comment 13 Fedora Update System 2017-06-23 06:26:22 UTC
acl-2.2.52-15.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-2028746562

Comment 14 Fedora Update System 2017-06-23 14:20:18 UTC
acl-2.2.52-15.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 15 Fedora Update System 2017-06-25 21:22:30 UTC
acl-2.2.52-13.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.

Comment 16 Kamil Dudka 2017-06-26 06:13:26 UTC
Not yet fixed in RHEL-7.

Comment 23 errata-xmlrpc 2018-04-10 13:13:40 UTC
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-2018:0772