Bug 1321373 - growpart on disk larger than 2TB fails
Summary: growpart on disk larger than 2TB fails
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: cloud-utils-growpart
Version: 7.0 (Kilo)
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: async
: 9.0 (Mitaka)
Assignee: Lars Kellogg-Stedman
QA Contact: Leonid Natapov
URL:
Whiteboard:
: 1372206 (view as bug list)
Depends On:
Blocks: 1372206
TreeView+ depends on / blocked
 
Reported: 2016-03-25 20:37 UTC by Andreas Karis
Modified: 2020-12-11 12:07 UTC (History)
15 users (show)

Fixed In Version: cloud-utils-growpart-0.29-1.el7
Doc Type: Bug Fix
Doc Text:
Prior to this update, using the growpart command on a disk larger than 2 TB that had an MBR partition table caused the partition table not to be updated correctly. As a consequence, the partition was in some cases shrunk, which corrupted the file system on the disk. With this update, growpart handles disks larger than 2 TB properly, and the described problem no longer occurs.
Clone Of:
: 1372206 (view as bug list)
Environment:
Last Closed: 2017-04-04 15:25:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 2595821 0 None None None 2016-09-01 09:57:02 UTC
Red Hat Product Errata RHBA-2017:0871 0 normal SHIPPED_LIVE cloud-init and cloud-utils-growpart bug fix and enhancement update 2017-04-04 19:25:15 UTC

Description Andreas Karis 2016-03-25 20:37:44 UTC
Description of problem:
Upstream bug:
https://bugs.launchpad.net/ubuntu/+source/cloud-utils/+bug/1259703

Version-Release number of selected component (if applicable):
cloud-utils-growpart-0.27-13.el7.noarch

How reproducible:
confirmed in 2 cases, but probably all of the time

Steps to Reproduce:
1. Refer to upstream bug report
2. in OSP 7, overcloud nodes with disks > 2TiB end up with random root partition size

Actual results:


Expected results:


Additional info:

Is it possible that we run into [1], which wasn't fixed in [2], and the root cause is [3] and [4]?

[1] https://bugs.launchpad.net/ubuntu/+source/cloud-utils/+bug/1259703
[2]  I guess that there is a high risk that our rpm is older than cannonical's patch in [1] (I didn't bother to check the source code, though)
[root@overcloud-controller-0 ~]# rpm -ql --changelog cloud-utils-growpart-0.27-13.el7.noarch
* Tue Mar 18 2014 Lars Kellogg-Stedman <lars> - 0.27-13
- suppress partx usage error

* Tue Jan 14 2014 Lars Kellogg-Stedman <lars> - 0.27-11
- import into RHEL
[3] We still use MBR on the overcloud
Model: Virtio Block Device (virtblk)
Disk /dev/vda: 64.4GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  2097kB  1049kB  primary
 2      2097kB  64.4GB  64.4GB  primary  xfs          boot

[4] https://en.wikipedia.org/wiki/Master_boot_record
(...)
MBR partition entries and the MBR boot code used in commercial operating systems, however, are limited to 32 bits. Therefore, the maximum disk size supported on disks using 512-byte sectors (whether real or emulated) by the MBR partitioning scheme (without using non-standard methods) is limited to 2 TiB
(...)

Comment 7 Masaki Furuta ( RH ) 2016-10-21 01:42:36 UTC
Hi,

I'm wondering if we may need fix on Bug 1290272 to have over 2TB partition with UEFI.

I think some of important customer strongly want to get over 2TB partition with EFI on ironic deployment too

Could we proceed this sooner to achieve it on both growpart side and ironic side?

Comment 10 Masaki Furuta ( RH ) 2016-10-28 07:04:51 UTC
Hi Lars,

After checking upstream for a while, we need following fixes in newer revision as well to ensure customer's request to have over 2TB partition with growpart, since only with revision 250, we'll just not prevent crash but can not create partition with gpt and (convert mbr to gpt if there ).

I agree that this may need rebase again though this is important parts for deployment and we have to handle this with extreme care on OSP8 repo.., but I think it's also fact this is sort of simple shell script and we may be able to have clear fix for it.

Can you pleaese take a look into this to triage this?

- use sfdisk 2.26 if available for gpt resizing
  http://bazaar.launchpad.net/~cloud-utils-dev/cloud-utils/trunk/revision/266.1.14

- growpart: when growing dont grow past the secondary gpt table
  http://bazaar.launchpad.net/~cloud-utils-dev/cloud-utils/trunk/revision/269#bin/growpart


Thank you,

Comment 12 Lars Kellogg-Stedman 2016-12-05 15:38:59 UTC
Upstream has finally produced some new releases, so I am working on a 0.7.8 package this week. I will update this bz as soon as that is available.

Comment 13 Lars Kellogg-Stedman 2016-12-05 15:48:15 UTC
So, the previous comment is misleading because I was thinking "cloud-init" but of course this is "growpart".  I will add a new cloud-utils-growpart release to my todo list...

Comment 15 Mike Burns 2017-01-13 17:11:01 UTC
*** Bug 1372206 has been marked as a duplicate of this bug. ***

Comment 32 Ruchika K 2017-03-10 15:21:33 UTC
is it possible to list the instructions here if someone currently on the latest RH supported OSP10 version wants to test the bug fix (which is currently on QA) ?
Thank you

Comment 33 Dana Safford 2017-03-11 03:58:02 UTC
Raising the Customer Escalation Flag.

Comment 34 Jaison Raju 2017-03-11 14:21:44 UTC
On a KVM-virtualization based director environment , i was able to test successfully with msdos partition :

[heat-admin@overcloud-controller-0 ~]$ sudo parted /dev/sda print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sda: 4374GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  2097kB  1049kB  primary
 2      2097kB  2199GB  2199GB  primary  xfs          boot

[heat-admin@overcloud-controller-0 ~]$ df -hT
Filesystem     Type      Size  Used Avail Use% Mounted on
/dev/sda2      xfs       2.0T  3.4G  2.0T   1% /
devtmpfs       devtmpfs  5.7G     0  5.7G   0% /dev
tmpfs          tmpfs     5.7G     0  5.7G   0% /dev/shm
tmpfs          tmpfs     5.7G  704K  5.7G   1% /run
tmpfs          tmpfs     5.7G     0  5.7G   0% /sys/fs/cgroup
tmpfs          tmpfs     1.2G     0  1.2G   0% /run/user/1000

---------------------------
I also tested disk label as gpt with the following commands & it worked out as expected :
ironic node-update <node-uuid> add properties/capabilities='disk_label:gpt'
nova flavor-key baremetal set capabilities:disk_label="gpt"


[heat-admin@overcloud-controller-0 ~]$ df -hT
Filesystem     Type      Size  Used Avail Use% Mounted on
/dev/sda3      xfs       4.0T  3.5G  4.0T   1% /
devtmpfs       devtmpfs  5.7G     0  5.7G   0% /dev
tmpfs          tmpfs     5.7G     0  5.7G   0% /dev/shm
tmpfs          tmpfs     5.7G  444K  5.7G   1% /run
tmpfs          tmpfs     5.7G     0  5.7G   0% /sys/fs/cgroup
tmpfs          tmpfs     1.2G     0  1.2G   0% /run/user/1000
[heat-admin@overcloud-controller-0 ~]$ sudo parted /dev/sda print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sda: 4374GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system  Name     Flags
 1      1049kB  2097kB  1049kB               primary  bios_grub
 2      2097kB  3146kB  1049kB               primary
 3      3146kB  4374GB  4374GB  xfs          primary


All results look as expected . Was there any thing else that needed testing ?

Comment 39 errata-xmlrpc 2017-04-04 15:25:54 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.

https://access.redhat.com/errata/RHBA-2017:0871


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