Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Created attachment 517736[details]
df -h human_round_to_nearest patch
Description of problem:
Actually just sent this to bug-coreutils but posting it here as well.
We have a 37TB filesystem that shows up in the output of df -h as 38TB :
Filesystem Size Used Avail Use% Mounted on
blue:/sas2fs03/ 38T 24T 14T 63% /blue/sas2
df -k shows :
Filesystem 1K-blocks Used Available Use% Mounted on
blue:/sas2fs03/ 39741816832 25020650784 14721166048 63% /blue/sas2
39741816832 is definitely much closer to 37TB than to 38TB :
% echo "39741816832 / (1024^3)" | bc -l
37.01245117187500000000
38TB would be :
% echo "38*1024^3" | bc -l
40802189312 (in 1K-blocks) which is >> 39741816832 (difference of 1060372480 KB)
With my suggested patch, I get correct output :
coreutils-8.9/src% ./df -h /blue/sas2
Filesystem Size Used Avail Use% Mounted on
blue:/sas2fs03/ 37T 23T 14T 63% /blue/sas2
Thanks,
Sabuj Pattanayek
Version-Release number of selected component (if applicable):
coreutils 8.4 to current 8.9
How reproducible:
always
Steps to Reproduce:
1. run df -h
Actual results:
Doesn't round properly
Expected results:
Should round properly
Additional info:
Thanks for suggestion and patch - btw. current version is not 8.9, but 8.12 - but this doesn't matter in that case.
Anyway I don't see your email on bug-coreutils mailing list at the moment ... maybe some mailinglist delay...
Based on the fact that the patch was rejected by upstream (as not consistent with other utilities and POSIX formats standards), closing this bugzilla WONTFIX. If you plan to propose the other way (gnulib change allowing consistency between utilities) to upstream, feel free to reopen this bugzilla once accepted.
Created attachment 517736 [details] df -h human_round_to_nearest patch Description of problem: Actually just sent this to bug-coreutils but posting it here as well. We have a 37TB filesystem that shows up in the output of df -h as 38TB : Filesystem Size Used Avail Use% Mounted on blue:/sas2fs03/ 38T 24T 14T 63% /blue/sas2 df -k shows : Filesystem 1K-blocks Used Available Use% Mounted on blue:/sas2fs03/ 39741816832 25020650784 14721166048 63% /blue/sas2 39741816832 is definitely much closer to 37TB than to 38TB : % echo "39741816832 / (1024^3)" | bc -l 37.01245117187500000000 38TB would be : % echo "38*1024^3" | bc -l 40802189312 (in 1K-blocks) which is >> 39741816832 (difference of 1060372480 KB) With my suggested patch, I get correct output : coreutils-8.9/src% ./df -h /blue/sas2 Filesystem Size Used Avail Use% Mounted on blue:/sas2fs03/ 37T 23T 14T 63% /blue/sas2 Thanks, Sabuj Pattanayek Version-Release number of selected component (if applicable): coreutils 8.4 to current 8.9 How reproducible: always Steps to Reproduce: 1. run df -h Actual results: Doesn't round properly Expected results: Should round properly Additional info: