Bug 2054950 - A large number is showing on disk size field
Summary: A large number is showing on disk size field
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Console Kubevirt Plugin
Version: 4.10
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: 4.11.0
Assignee: Hilda Stastna
QA Contact: Guohua Ouyang
Depends On:
Blocks: 2074895
TreeView+ depends on / blocked
Reported: 2022-02-16 04:41 UTC by Guohua Ouyang
Modified: 2022-06-15 18:12 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: Size is always in bytes Consequence: A none user friendly number is displayed Fix: Process the bytes using a "humanize" method that show the SI units correctly Result: Size is display using Byte SI units. For example "1024B" will be displayed as "1KiB".
Clone Of:
Last Closed:
Target Upstream Version:

Attachments (Terms of Use)
large disk size (2.41 MB, application/octet-stream)
2022-02-16 04:41 UTC, Guohua Ouyang
no flags Details
large number on storage step while using templates which has auto-updated boot source (1.67 MB, application/octet-stream)
2022-03-21 23:27 UTC, Guohua Ouyang
no flags Details

System ID Private Priority Status Summary Last Updated
Github openshift console pull 11105 0 None open Bug 2054950: Display correct disk size in Edit disk modal 2022-02-26 11:32:14 UTC

Description Guohua Ouyang 2022-02-16 04:41:42 UTC
Created attachment 1861398 [details]
large disk size

Description of problem:
While create vm from templates which has boot source, a large number showing disk size field, user may did not notice it and continue save the disk. Which cause the VM disk is too large.

This is a supplyment of bug https://bugzilla.redhat.com/show_bug.cgi?id=2046598, so we won't miss it.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. create vm from a template which has boot source
2. edit disk on storage step(customize wizard)

Actual results:

Expected results:

Additional info:

Comment 2 Guohua Ouyang 2022-02-16 12:33:16 UTC
(In reply to Hilda Stastna from comment #1)
> Hi Guohua,
> to be more specific, the problem is incorrect units or the disk size
> displayed in bytes instead of Gib, in the "Edit disk" modal window. But I
> would like to make sure about the expected result. Should the disk size be
> displayed in GiB in that window? Also let's make sure about the behavior
> when changing units - The value doesn't change when changing GiB to MiB/TiB.
> Is this expected behavior? Thanks!

the problem is it loads with a large number and unit GiB.
the expected results is it loads a small number and unit GiB, a large number is not readable.

Comment 5 Guohua Ouyang 2022-02-28 01:49:03 UTC
Tests should cover three scenarios:
1. create VM from template has no boot source
2. create VM from template has manual updated boot source
3. create VM from template which has auto-updated boot source

Test on master which has the PR included, the first 2 scenarios are PASS, but failed on the scenario 3, it still shows a large number on storage and edit disk modal.

Comment 6 Guohua Ouyang 2022-03-21 23:27:37 UTC
Created attachment 1867326 [details]
large number on storage step while using templates which has auto-updated boot source

Comment 7 Guohua Ouyang 2022-03-23 00:07:26 UTC
Test it on latest master and 4.11, the problem #1, #2, #3 are not reproduced any more.
move the bug back to ON_QA.

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