Skip to content

On Fedora Rawhide, rpm --erase leaves empty directories on disk #3762

Description

@omajid

Describe the bug

After I remove a package via dnf remove or rpm --erase, some empty directories on left on disk

To Reproduce
Steps to reproduce the behavior:

  1. podman run --pull=newer -it fedora:rawhide /bin/bash
  2. dnf install -y koji
  3. koji download-build -a $(uname -m) dotnet9.0-9.0.106-1.fc43
  4. dnf install *rpm
  5. rpm --erase $(rpm -qa '*dotnet*' 'aspnetcore*' 'netstandard*')
  6. find /usr/lib64/dotnet/

Expected behavior

No files should have been left on disk. The output of find should be an error about that path not existing.

Output

# find /usr/lib64/dotnet/
/usr/lib64/dotnet/
/usr/lib64/dotnet/packs

Environment

  • OS / Distribution: Fedora Rawhide
  • Version: RPM version 5.99.90

Additional context

This is the package: https://src.fedoraproject.org/rpms/dotnet9.0/c/c2c2d69fb0381a0dc987c86d9a2d0f902b302918?branch=rawhide

I built this exact commit on all Fedora branches. This issue of stale files left on disk after package is uninstalled only happened on Fedora Rawhide, not on 42 or 41. The order or number of uninstalling the package might matter: I removed the subpackages that own /usr/lib64/dotnet/packs one-by-one, and when I uninstalled dotnet-apphost-pack-9.0 last, the directory got removed correctly.

Activity

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

Metadata

Metadata

Assignees

Type

Projects

  • Status
    Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions