- 
    
Bug
 - 
    Resolution: Done-Errata
 - 
    
Major
 - 
    rhel-9.4
 
- 
        rpm-4.16.1.3-37.el9
 - 
        None
 - 
        Low
 
- 
        rhel-swm
 - 
        ssg_core_services
 
- 
        22
 - 
        24
 - 
        0
 - 
        False
 - 
        False
 - 
        
 - 
        None
 - 
        Red Hat Enterprise Linux
 - 
        None
 
- 
        
 - 
        Pass
 - 
        Automated
 
- 
        Release Note Not Required
 
- 
        None
 
What were you trying to do that didn't work?
A customer hit an issue with installing a kernel (which pushes files in /lib directory in particular), I was getting the following error message:
  Installing       : kernel-core-4.18.0-513.18.1.el8_9.x86_64                                                             1/2 
error: failed to open dir lib of /lib/: Not a directory
Error unpacking rpm package kernel-core-4.18.0-513.18.1.el8_9.x86_64
[...]
After much digging, it was found that /lib exited and was the appropriate symlink to /usr/lib but /lib was owned by some non-root user.
The error message tends to indicate the errno of a previous C function was reused inadvertently.
Please provide the package NVR for which bug is seen:
rpm-libs-4.14.3-28.el8_9
How reproducible:
Always
Steps to reproduce
- Change ownership of /lib symlink
 
# useradd user # chown -h user /lib
 - Install a kernel
 
# yum install kernel-core-4.18.0-513.18.1.el8_9
 
Expected results
Some self-explanatory error message
Actual results
Cryptic misleading message
- is cloned by
 - 
                    
RHEL-73186 dnf fails with misleading "cpio: open failed - Not a directory" error message
-         
 - Closed
 
 -         
 - 
                    
RHEL-33397 dnf fails with misleading "cpio: open failed - Not a directory" error message
-         
 - Closed
 
 -         
 
- links to
 - 
                    
        
        RHBA-2024:142383
        rpm bug fix and enhancement update