RPM creation fails with prelink installed under centos/oel #352

Closed
eklein opened this Issue Jan 29, 2013 · 5 comments

Projects

None yet

5 participants

@eklein
[root@somesystem jvm]# fpm -s dir -t rpm -n "custom-java" -v "1.0.3" -a noarch --prefix=/usr/lib/jvm jdk1.6.0_31 jdk1.7.0_11
Created rpm {:path=>"custom-java-1.0.3-1.noarch.rpm"}
[root@somesystem jvm]# rpm -Fvh custom-java-1.0.3-1.noarch.rpm
Preparing...                ########################################### [100%]
   1:java-rally             ########################################### [100%]
error: unpacking of archive failed on file /usr/lib/jvm/jdk1.6.0_31/bin/appletviewer;50fdc4dd: cpio: Digest mismatch

I've reproduced this under CentOS 5.7 and OEL 6.2 with fpm 0.4.29 and older.

Uninstalling the prelink package allows the RPM to be created properly.

@waldman

Thanks...

Had a similar problem with another package and the removal of the prelink fixed.

@hoggle64

Hi,

I am on RHEL 6.4 and the solution with removing the prelink package did not work(see below)

any other ideas ?

[as24build@dsvncgv001 ~]$ fpm --verbose --directories=commandline --description "talend commandline file bundle" --prefix /data/talend -a noarch -v 5.2.1 --iteration 1 -n as24_talend_commandline --workdir /home/as24build/ -s dir -t rpm commandline
Setting from flags: architecture=noarch {:level=>:info}
Setting from flags: description=talend commandline file bundle {:level=>:info}
Setting from flags: epoch= {:level=>:info}
Setting from flags: iteration=1 {:level=>:info}
Setting from flags: name=as24_talend_commandline {:level=>:info}
Setting from flags: url=http://example.com/no-uri-given {:level=>:info}
Setting from flags: version=5.2.1 {:level=>:info}
Setting from flags: architecture=noarch {:level=>:info}
Converting dir to rpm {:level=>:info}
no value for epoch is set, defaulting to nil {:level=>:warn}
Reading template {:level=>:info, :path=>"/usr/lib/ruby/gems/1.8/gems/fpm-0.4.34/templates/rpm.erb"}
no value for epoch is set, defaulting to nil {:level=>:warn}
Running rpmbuild {:args=>["rpmbuild", "-bb", "--define", "buildroot /home/as24build/package-rpm-build20130507-5363-11wsjj2/BUILD", "--define", "_topdir /home/as24build/package-rpm-build20130507-5363-11wsjj2", "--define", "_sourcedir /home/as24build/package-rpm-build20130507-5363-11wsjj2", "--define", "_rpmdir /home/as24build/package-rpm-build20130507-5363-11wsjj2/RPMS", "/home/as24build/package-rpm-build20130507-5363-11wsjj2/SPECS/as24_talend_commandline.spec"], :level=>:info}
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.rOSZTJ {:level=>:info}
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.QxZqnT {:level=>:info}
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.lYIdR2 {:level=>:info}
Processing files: as24_talend_commandline-5.2.1-1.noarch {:level=>:info}
error: create archive failed on file /home/as24build/package-rpm-build20130507-5363-11wsjj2/BUILD/data/talend/commandline/plugins/org.talend.designer.components.localprovider_5.2.1.r95165/components/tAmazonOracleInput/xmlparserv2.jar: cpio: Bad magic {:level=>:error}
{:level=>:info}
{:level=>:info}
RPM build errors: {:level=>:info}
create archive failed on file /home/as24build/package-rpm-build20130507-5363-11wsjj2/BUILD/data/talend/commandline/plugins/org.talend.designer.components.localprovider_5.2.1.r95165/components/tAmazonOracleInput/xmlparserv2.jar: cpio: Bad magic {:level=>:error}
Process failed: rpmbuild failed (exit code 1). Full command was:["rpmbuild", "-bb", "--define", "buildroot /home/as24build/package-rpm-build20130507-5363-11wsjj2/BUILD", "--define", "_topdir /home/as24build/package-rpm-build20130507-5363-11wsjj2", "--define", "_sourcedir /home/as24build/package-rpm-build20130507-5363-11wsjj2", "--define", "_rpmdir /home/as24build/package-rpm-build20130507-5363-11wsjj2/RPMS", "/home/as24build/package-rpm-build20130507-5363-11wsjj2/SPECS/as24_talend_commandline.spec"] {:level=>:error}

@hoggle64

good news on this one !

Building the rpm seems to consume huge amount of disk space( I guess twice or three times as much as the sources). What happend here was that behind the scenes I was running out of space which I didn't notice.
Then cpio came out with this strange error message which did not point me in the right direction....

D'oh !

@r4um
Collaborator

Duplicate of #262. Closing.

@r4um r4um closed this Aug 2, 2013
@wallrj wallrj referenced this issue in ClusterHQ/flocker Oct 15, 2014
Merged

Sumo package builder - 508 #868

@wallrj wallrj added a commit to ClusterHQ/flocker that referenced this issue Oct 16, 2014
@wallrj wallrj Remember to check and remove prelink. See jordansissel/fpm#352 00cf68f
@Hrusikesh4302

thanks @hoggle64 , worked for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment