Bug 1634200

Summary: /bin/basename does not appear as provided by coreutils-single
Product: [Fedora] Fedora Reporter: Uri Simchoni <urisimchoni>
Component: coreutilsAssignee: Kamil Dudka <kdudka>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: admiller, dornelas, jamartis, jarodwilson, kdudka, kzak, ooprala, ovasik, p, rkudyba, skisela, twaugh, urisimchoni, v.podzimek+fedora
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-11-05 12:54:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Uri Simchoni 2018-09-28 22:21:06 UTC
Description of problem:
/bin/basename does not appear as provided by coreutils-single when querying the fedora repository. This causes installation of an rpm file (Oracle Java JDK8) to fail.


Version-Release number of selected component (if applicable):
coreutils-single-8.29-7.fc28.x86_64

How reproducible:
Always

Steps to Reproduce:
1. spin-up a fedora 28 container:
docker run -it --rm fedora:latest /bin/bash
2. use the following commands:
[root@a6cdd04a835c /]# rpm -q coreutils-single
coreutils-single-8.29-7.fc28.x86_64
[root@a6cdd04a835c /]# ls -l /bin/basename  
-r-xr-xr-x. 1 root root 55 May 29 16:33 /bin/basename
[root@a6cdd04a835c /]# rpm -q --whatprovides /bin/basename
coreutils-single-8.29-7.fc28.x86_64
[root@a6cdd04a835c /]# dnf repoquery --whatprovides /bin/basename
Last metadata expiration check: 0:15:37 ago on Fri Sep 28 21:55:41 2018.
coreutils-0:8.29-5.fc28.x86_64
coreutils-0:8.29-7.fc28.x86_64


Actual results:
/bin/basename is installed, and shows up in local rpm query, but does not show up in repoquery. That appears to be causing a dnf install of an .rpm file which requires /bin/basename to fail.

Expected results:
repoquery should list coreutils-single as well.

Additional info:

By comparison, searching for /usr/bin/basename yields both coreutils and coreutils-single as candidates:

[root@a6cdd04a835c /]# dnf repoquery --whatprovides /usr/bin/basename
Last metadata expiration check: 0:19:26 ago on Fri Sep 28 21:55:41 2018.
coreutils-0:8.29-5.fc28.x86_64
coreutils-0:8.29-7.fc28.x86_64
coreutils-single-0:8.29-5.fc28.x86_64
coreutils-single-0:8.29-7.fc28.x86_64

Comment 1 Kamil Dudka 2018-10-01 12:10:30 UTC
Please report this bug to Oracle.  coreutils installs /usr/bin/basename since Fedora 17.  /bin/basename is only reachable via the /bin -> /usr/bin/ symlink.

Comment 2 Derrick Ornelas 2018-11-02 17:02:02 UTC
This seems like a coreutils packaging bug to me, as it previously provided /bin/basename until now.


$ rpm -qp --provides http://download.fedoraproject.org/pub/fedora/linux/updates/27/x86_64/Packages/c/coreutils-8.27-21.fc27.x86_64.rpm | grep basename
/bin/basename


$ rpm -qp --provides http://download.fedoraproject.org/pub/fedora/linux/updates/28/Everything/x86_64/Packages/c/coreutils-8.29-7.fc28.x86_64.rpm | grep basename
/bin/basename


$ rpm -qp --provides http://download.fedoraproject.org/pub/fedora/linux/updates/29/Everything/x86_64/Packages/c/coreutils-8.30-5.fc29.x86_64.rpm | grep basename | wc -l
0

Comment 3 Kamil Dudka 2018-11-02 17:07:19 UTC
It was (intentionally) dropped in the following commit:

https://src.fedoraproject.org/cgit/rpms/coreutils.git/commit/?id=e9599c82

Comment 4 Kamil Dudka 2021-03-30 14:22:41 UTC
*** Bug 1944688 has been marked as a duplicate of this bug. ***