Bug 731692 - satellite-sync fails hard on basic math
Summary: satellite-sync fails hard on basic math
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Satellite Synchronization
Version: 541
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
Assignee: Miroslav Suchý
QA Contact: Jan Hutař
URL:
Whiteboard:
Depends On:
Blocks: sat54-blockers
TreeView+ depends on / blocked
 
Reported: 2011-08-18 11:26 UTC by Martin Minar
Modified: 2016-07-04 00:56 UTC (History)
5 users (show)

Fixed In Version: spacewalk-backend-1.2.13-56
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-11-21 09:45:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1466 0 normal SHIPPED_LIVE Red Hat Network Satellite server spacewalk-backend bug fix update 2011-11-21 14:43:48 UTC

Description Martin Minar 2011-08-18 11:26:04 UTC
Description of problem:
When syncing channel on Satellite, counting of remaining data to be downloaded is not exactly right.

Version-Release number of selected component (if applicable):
Satellite 5.4.1
spacewalk-backend-tools-1.2.13-52.el5sat

How reproducible:
1 of 1

Steps to Reproduce:
1. satellite-sync of channel bigger then 1GB (approximately 1000 packages) - in this particular case: satellite-sync -c redhat-linux-s390x-7.1 --no-errata --no-kickstarts
  
Actual results:
[..snip..]
06:32:32       Downloaded 1022.277 MB of 1.22 GB. Estimated remaining time: 0:00:33.720000
06:32:32     966/977 Fetch successful: kde-i18n-Serbian-2.2.2-0.71.0.noarch.rpm (599727 bytes)
06:32:35       Downloaded 1.0 GB of 1.22 GB. Estimated remaining time: 0:00:33.760000
06:32:35     967/977 Fetch successful: kde-i18n-Slovak-2.2.2-0.71.0.noarch.rpm (2208175 bytes)
06:32:39       Downloaded 1.4 GB of 1.22 GB. Estimated remaining time: 0:00:16.920000
06:32:39     968/977 Fetch successful: kde-i18n-Slovenian-2.2.2-0.71.0.noarch.rpm (4023483 bytes)
06:32:42       Downloaded 1.6 GB of 1.22 GB. Estimated remaining time: 0:00:16.950000
06:32:42     969/977 Fetch successful: kde-i18n-Spanish-2.2.2-0.71.0.noarch.rpm (2661500 bytes)
06:32:46       Downloaded 1.8 GB of 1.22 GB. Estimated remaining time: 0:00:16.990000
06:32:46     970/977 Fetch successful: kde-i18n-Swedish-2.2.2-0.71.0.noarch.rpm (2242260 bytes)
06:32:47       Downloaded 1.9 GB of 1.22 GB. Estimated remaining time: 0:00:17.010000
06:32:47     971/977 Fetch successful: kde-i18n-Tamil-2.2.2-0.71.0.noarch.rpm (560364 bytes)
06:32:49       Downloaded 1.9 GB of 1.22 GB. Estimated remaining time: 0:00:17.030000
06:32:49     972/977 Fetch successful: kde-i18n-Thai-2.2.2-0.71.0.noarch.rpm (527574 bytes)
06:32:51       Downloaded 1.10 GB of 1.22 GB. Estimated remaining time: 0:00:17.040000
06:32:51     973/977 Fetch successful: kde-i18n-Turkish-2.2.2-0.71.0.noarch.rpm (935862 bytes)
06:32:52       Downloaded 1.11 GB of 1.22 GB. Estimated remaining time: 0:00:17.060000
[..snip..]

Expected results:
Basic math rules apply...
Eg. 1.04 of 1.22GB
    1.06 of 1.22GB
    1.09 of 1.22GB

Additional info:

* http://en.wikipedia.org/wiki/Algebra
* http://en.wikipedia.org/wiki/Real_number

Comment 1 Miroslav Suchý 2011-08-18 14:13:04 UTC
Fixed in Spacewalk.git in commit b59ac75ba462262a33e18a63d1486ef56376af89
Note that I also flipped GB to GiB in commit 061d90567aadd89541764ac8a97068e893113c81, but that is probabaly beyond this BZ.

Comment 3 Michael Mráka 2011-10-24 14:18:11 UTC
One more relevant commit in spacewalk master:
commit 17655a026da3c251857ed2da575f5b137ee5aee0
    731692 - make number formating consistent across all units

Comment 4 Michael Mráka 2011-10-26 08:56:37 UTC
Backported to SATELLITE-5.4 as
commit e5b7975f84daa7aabae70cbb1679fd9b30ae0c92
    731692 - make number formating consistent across all units
commit db9953b548d8100386c9614995e21aff5a17f25d
    if we use 1024 as base, we should use kiB, MiB, GiB
commit 0959427713e6ed9664fa99c899f7b6d2197424fa
    731692 - correct output of number beyond decimal point in sat-sync

Comment 7 errata-xmlrpc 2011-11-21 09:45:02 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1466.html


Note You need to log in before you can comment on or make changes to this bug.