Bug 1005480 - mock builds for epel-5-x86_64 fail at unpacking of cpio archive: md5 sum mismatch
mock builds for epel-5-x86_64 fail at unpacking of cpio archive: md5 sum mism...
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: mock (Show other bugs)
19
x86_64 Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Clark Williams
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-09-07 09:02 EDT by David Timms
Modified: 2014-04-02 09:22 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-04-02 09:22:38 EDT
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)
mock's build.log indicating unpack failure. (24.12 KB, text/x-log)
2013-09-07 09:02 EDT, David Timms
no flags Details

  None (edit)
Description David Timms 2013-09-07 09:02:34 EDT
Created attachment 795109 [details]
mock's build.log indicating unpack failure.

Description of problem:
Attempting a mock build of a few different packages fails for epel-5-x86_64.

Version-Release number of selected component (if applicable):
mock-1.1.33-1.fc19.noarch

How reproducible:
Yes.

Steps to Reproduce:
1. yum install mock
2. mock -r epel-5-x86_64 --rebuild /home/davidt/rpmbuild/SRPMS/tnef-1.4.9-1.fc17.src.rpm 

Actual results:
Finish: device setup
Start: build setup for tnef-1.4.9-1.fc17.src.rpm
ERROR: Exception(/home/davidt/rpmbuild/SRPMS/tnef-1.4.9-1.fc17.src.rpm) Config(epel-5-x86_64) 0 minutes 15 seconds
INFO: Results and/or logs in: /var/lib/mock/epel-5-x86_64/result
ERROR: Command failed. See logs for output.
 # ['rpm', '-Uvh', '--nodeps', '/builddir/build/originals/tnef-1.4.9-1.fc17.src.rpm']


Expected results:
Build progresses past .src.rpm extract into actual build process.

Additional info:
/var/lib/mock/epel-5-x86_64/result/root/log:
DEBUG util.py:316:  Executing command: ['rpm', '-Uvh', '--nodeps', '/builddir/build/originals/tnef-1.4.9-1.fc17.src.rpm'] with env {'LANG': 'en_US.utf8', 'TERM': 'vt100', 'SHELL': '/bin/bash', 'CCACHE_DIR': '/tmp/ccache', 'HOSTNAME': 'mock', 'PROMPT_COMMAND': 'echo -n "<mock-chroot>"', 'HOME': '/builddir', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'CCACHE_UMASK': '002'}
DEBUG util.py:266:  tnef                        warning: user davidt does not exist - using root
DEBUG util.py:266:  warning: group davidt does not exist - using root
DEBUG util.py:266:  ##################################################
DEBUG util.py:266:  error: unpacking of archive failed on file /builddir/build/SOURCES/tnef-1.4.9.tar.gz;522b2173: cpio: MD5 sum mismatch
DEBUG util.py:356:  Child return code was: 1
DEBUG util.py:316:  Executing command: ['/bin/umount', '-n', '/var/lib/mock/epel-5-x86_64/root/proc/filesystems'] with env {'LANG': 'en_US.utf8', 'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOSTNAME': 'mock', 'HOME': '/builddir', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin'}
DEBUG util.py:356:  Child return code was: 0
DEBUG util.py:316:  Executing command: ['/bin/um
Comment 1 David Timms 2013-09-15 07:40:50 EDT
Will this be because el5 doesn't have the new packing type inside the rpm that fedora 19 etc has ?

Is there a workaround ?
Comment 2 Clark Williams 2013-09-27 17:57:26 EDT
This sort of problem has always plagued us. At some point the host environment moves far enough away from an old target that it's almost impossible to get builds working. That's why the koji builders for RHEL5 are running older versions of mock. 

The thing that's failing is the installation of the SRPM inside the chroot. This is done with the chroot rpm, meaning the target distro package, which in this case is the old epel5 rpm, which does md5 verification of the archive. I'll look at allowing a --nomd5 option (or --nofiledigest on later fedora's) inside the chroot to see if we can keep building epel5 packages on fedora. 

The only workaround I can suggest trying is to rebuild the SRPM on an epel5 box (or inside a mock chroot using mock --shell) and build he resulting SRPM with mock. You still may encounter rpm difference problems due to rpmdb changes.
Comment 3 Miroslav Suchý 2014-04-02 09:22:38 EDT
You will get exactly same error if you will build using rpmbuild in native RHEL5.

The correct solution is to create srpm using:
  rpmbuild --define "_source_filedigest_algorithm md5"

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