Bug 1474757

Summary: crypto-policies broken in build root on x86_64 due to "missing" cat command
Product: [Fedora] Fedora Reporter: Daniel BerrangĂ© <berrange>
Component: crypto-policiesAssignee: Igor Gnatenko <ignatenko>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 27CC: ffesti, lslebodn, nmavrogi
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-09-30 13:00:52 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
Diffs in build root since previous successful build none

Description Daniel Berrangé 2017-07-25 10:51:05 UTC
Created attachment 1304166 [details]
Diffs in build root since previous successful build

Description of problem:

I attempted to build libvirt in rawhide


When installing crypto-policies in the build root we see errors thrown

DEBUG util.py:439:  /usr/bin/update-crypto-policies: line 56: cat: command not found
DEBUG util.py:439:  /usr/bin/update-crypto-policies: line 66: cat: command not found
DEBUG util.py:439:  warning: %post(crypto-policies-20170606-2.git7c32281.fc27.noarch) scriptlet failed, exit status 1


This in turn causes libvirt's test suite to fail because the SYSTEM policy is not created

TEST: virnettlssessiontest
 1) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 2) TLS Session servercertreq.filename + clientcertaltreq.filename    ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 3) TLS Session servercertalt1req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 4) TLS Session servercertalt1req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 5) TLS Session servercertalt1req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 6) TLS Session servercertalt2req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 7) TLS Session servercertalt2req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 8) TLS Session servercertalt2req.filename + clientcertreq.filename   ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
 9) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
10) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
11) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
12) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
13) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
14) TLS Session servercertreq.filename + clientcertreq.filename       ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
15) TLS Session servercertlevel3areq.filename + clientcertlevel2breq.filename ... libvirt: XML-RPC error : Failed to set TLS session priority to @LIBVIRT,SYSTEM: The request is invalid.
FAILED
FAIL virnettlssessiontest (exit status: 1)
+ exit 1

https://koji.fedoraproject.org/koji/taskinfo?taskID=20721206


What's odd though is that the root.log does show 'coreutils' being installed, so 'cat' should be present.

It is also strange that it only affected x86_64

I'll attach a file showing a diff between all the packages present in the build root since the previous successful build

Version-Release number of selected component (if applicable):
20170606-2.git7c32281


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Daniel Berrangé 2017-07-25 12:35:05 UTC
It is unclear from the logs what order DNF installed the packages in. I wonder if it is possible that crypto-policies is installed before coreutils, because there's no  "Requires(post): coreutils" in crypto-policies to force the install ordering.

Comment 2 Nikos Mavrogiannopoulos 2017-07-25 12:45:07 UTC
Adding Igor who modified the spec to remove "Requires(post): coreutils"

Comment 3 Igor Gnatenko 2017-07-25 12:57:27 UTC
I've had discussion with Florian about this Requires(post) and my understanding was that all dependencies of crypto-policies must be installed *before* scriptlets run. And adding Requires(post): for coreutils should be hint only for circular deps which one to install first..

So it is something wrong here. Florian, could you help us here please?

Comment 4 Nikos Mavrogiannopoulos 2017-07-25 15:54:29 UTC
*** Bug 1474886 has been marked as a duplicate of this bug. ***

Comment 7 Jan Kurik 2017-08-15 06:51:52 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle.
Changing version to '27'.

Comment 8 Florian Festi 2020-01-31 07:32:28 UTC
Clear needinfo