Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RPM error: unpacking of archive failed: cpio: Bad magic

Status
Not open for further replies.

nychris

MIS
Dec 4, 2004
103
US
I have a weird issue on a RHEL3 Update 8 server. This happens with every RPM package. Any ideas?

Code:
bash-2.05b# rpm -ivh openssh-3.6.1p2-33.30.9.i386.rpm
error: openssh-3.6.1p2-33.30.9.i386.rpm: V3 DSA signature: BAD, key ID db42a60e
error: openssh-3.6.1p2-33.30.9.i386.rpm cannot be installed
 
# added --nosignature here

bash-2.05b# rpm -ivh openssh-3.6.1p2-33.30.9.i386.rpm --nosignature
error: openssh-3.6.1p2-33.30.9.i386.rpm: MD5 digest: BAD Expected(c3bc64fe97c9822bba08a2cd50d6fe81) != (aa6fe539081a507b7285d8b5e5a1767d)
error: openssh-3.6.1p2-33.30.9.i386.rpm cannot be installed
 
# added --nodigest here
 
 
bash-2.05b# rpm -ivh openssh-3.6.1p2-33.30.9.i386.rpm --nosignature --nodigest
Preparing...                ########################################### [100%]
   1:openssh                warning: /etc/ssh/moduli created as /etc/ssh/moduli.rpmnew
########################################### [100%]
error: unpacking of archive failed on file /usr/bin/ssh-keygen;4898cab4: cpio: MD5 sum mismatch

 
# added --nomd5 here
 
 
# rpm -ivh openssh-3.6.1p2-33.30.9.i386.rpm --nosignature --nomd5 --nodigest
Preparing...                ########################################### [100%]
   1:openssh                warning: /etc/ssh/moduli created as /etc/ssh/moduli.rpmnew
########################################### [100%]
error: unpacking of archive failed: cpio: Bad magic
 

nychris,

The "rpm" package itself may be out of date. So, look for an update to the "rpm" package itself, install that, and try again with the other rpms.

 
The rpm package is current for U8, rpm-4.2.3-30. What I did notice is that glibc is however outdated for U8, glibc-2.3.2-95.45. You have to be careful with glibc though as it can hose a system if anything goes wrong. I'm going to look into possibly upgrading glibc to .47, or downgrading rpm to match the RH update version that glibc is running on. This will have to be done from rescue mode of course as RPM is currently broken on the system.
 
Are you certain the RPM files have not been corrupted by transferring in FTP ASCII mode or something? Have you tried running a manual md5sum against them and seeing if it agrees with what RPM is saying? And whether it agrees with the md5sums quoted on the source site/media (there are often md5sum lists included with the packages).

Annihilannic.
 
Annihilannic, the packages are fine. They are on an NFS share that is shared by 100's of servers. This is the only server having issues. Manually running md5sum gave a completely different checksum from either of the numbers.

I've tried booting into rescue mode and get the same errors even when using the rpm binary from the CD with the --root=/mnt/sysimage parameter.

I got desperate after seeing tons of odd behavior and decided to back up and try to kickstart new image. Even kickstart is failing with "cpio: Bad magic" errors which leads me to believe that there is a hardware or firmware issue. I had the datacenter team run hardware diagnostics which came up clean and now I'm going to ask them to upgrade the RAID firmware and BIOS.

I can post exact errors and more detailed information of what I saw in the rescue environment tomorrow if anyone is interested.
 
One thing I forgot to mention when I said "I've tried booting into rescue mode and get the same errors even when using the rpm binary from the CD with the --root=/mnt/sysimage parameter.". If I use the CD's rpm binary against RPMs on the CD itself, they are fine, but when I query those same packages after they are placed under /mnt/sysimage I get the errors above. As a test, I install the vsftpd rpm (just a random RPM package) from the CD using the --root option. It installed the files onto the disk, but hosed th RPM database. RPM commands return "Segmentation fault" now.

Hopefully the datacenter team can update the firmware tonight and I'll see where I'm at tomorrow with this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top