Bug 1378153

Summary: parted should print partition boundaries in sectors by default
Product: Red Hat Enterprise Linux 7 Reporter: John Pittman <jpittman>
Component: partedAssignee: Brian Lane <bcl>
Status: CLOSED WONTFIX QA Contact: Release Test Team <release-test-team>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.2   
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-21 18:04:12 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:
Attachments:
Description Flags
patch to print sectors by default
none
Test case patch reference none

Description John Pittman 2016-09-21 15:41:05 UTC
Created attachment 1203376 [details]
patch to print sectors by default

Description of problem:

In parted, by default, we print disk size and partition boundaries in compact form.  As partition boundaries fall on sector boundaries, this is not useful for administration and should be changed.

Version-Release number of selected component (if applicable):
parted-3.1-23.el7.x86_64

Actual results:
Partition information printed in compact form by default.

Expected results:
Should be printed in sectors

Additional info:

I will attach to the bug, a potential patch.  It seems to be fairly non-invasive as far as base functionality of parted.  If it seems usable, I would be glad to send it upstream to start a discussion/review there as well.

As the change is very front-facing, it broke a great deal of tests, all of which pass when edited to include the new parameters.  I will attach a second patch file, only as reference, of the changes made to tests to get the package built.  The values I added were static and only for testing, but the patch should show what tests will need to be changed and where.  If I'm able, I will post a proper patch for the tests as well.

Comment 1 John Pittman 2016-09-21 16:03:44 UTC
Created attachment 1203378 [details]
Test case patch reference

This patch is only a reference for the changes that would need to be done to the test suite if the main patch is accepted.

Comment 2 Brian Lane 2016-09-21 16:12:52 UTC
Most people don't care about sectors, they care about the size of the partitions. So I don't see any reason to make a change like this when you can set the size to be displayed by using the units command. eg. 'parted -s /dev/foo u s p free'

Additionally, a change like this isn't acceptable in a RHEL release. It is bound to break user scripts, as you found with the tests. If it were to change it would have to come from upstream and make its way through Fedora first, giving people a fair amount of time to adjust to it.

Comment 3 John Pittman 2016-09-21 16:25:45 UTC
Thanks for the information Brian.  Obviously I disagree with your initial statement.  I think users care about the "size" at creation, but after that, it's not useful at all, for example when printing, which is what the patch changes.  This is all, of course, coming from a support point of view.  We get a good view of what customers are doing here.  The reason I initially created this is because fdisk -l is now far more useful than parted -l; my peers and I preach parted use so I could not let this stand :)

I'll see what I can do as far seeing what upstream thinks.

Thanks again.  

John

Comment 4 RHEL Program Management 2016-09-21 18:04:12 UTC
Development Management has reviewed and declined this request.
You may appeal this decision by reopening this request.