The error message “unpacking of archive failed on file /usr/bin/xxxx: cpio: open Failed” indicates that the system failed to install the rpm since it cannot unpack the package under the /usr/bin directory.

For example, you may see the error message as stated below while installing a ‘nano’ package using yum

Error unpacking rpm package nano-1.x.x.i386 error: unpacking of archive failed on file /usr/bin/nano;4c70f874: cpio: open Failed:

This indicates that the file /usr/bin/nano cannot be created under the /usr/bin directory which mostly happens if an attribute is set on the directory.

Use ‘lsattr’ command to check the attributes set on the directory:

    root@server [~]# lsattr /usr | grep bin

If the output is something like the following, it states that the immutable bit (lowercase ‘i’) is set to the “/usr/bin” directory thus denying to write under that directory.

    ----i-----I-- /usr/bin

Use ‘chattr’ command to remove the attributes from the directory:

    root@server [~]# chattr -i /usr/bin

Once done, you can successfully install the rpm.

Incoming search terms: