GPT disk growroot fails in version .027 cloud-utills
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-utils |
Fix Released
|
Medium
|
Unassigned | ||
cloud-utils (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Cloud-utils version
ii cloud-guest-utils 0.27-0ubuntu9.1 cloud guest utilities
ii cloud-image-utils 0.27-0ubuntu9.1 cloud image management utilities
ii cloud-init 0.7.5-0ubuntu1 Init scripts for cloud instances
ii cloud-initramfs
ii cloud-utils 0.27-0ubuntu9.1 metapackage for installation of upstream cloud-utils source
When trying to provision a baremetal with disk greater than 2TB and using GPT.
We use Ironic Python agent which basically creates a config drive which is basically a 64 Mb disk at the end of the disk.
Then once the installation is complete box boots back , growpart fails giving a error
Now when trying growpart runs it fails as
growpart /dev/sda 3
failed [sgdisk_mod:4] sgdisk --move-
Could not create partition 3 from 8790016 to 22501064664
Could not change partition 3's type code to 0FC63DAF-
Unable to set partition 3's name to 'Linux filesystem'!
Error encountered; not saving changes.
FAILED: disk=/dev/sda partition=3: failed to repartition
***** WARNING: Resize failed, attempting to revert ******
Warning: The kernel is still using the old partition table.
The new table will be used at the next reboot.
The operation has completed successfully.
Below is the example of the disk Layout.
gdisk -l /dev/sda
GPT fdisk (gdisk) version 0.8.1
Partition table scan:
MBR: protective
BSD: not present
APM: not present
GPT: present
Found valid GPT with protective MBR; using GPT.
Disk /dev/sda: 22501195776 sectors, 10.5 TiB
Logical sector size: 512 bytes
Disk identifier (GUID): D7F2691D-
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 22501195742
Partitions will be aligned on 8-sector boundaries
Total free space is 22165520377 sectors (10.3 TiB)
Number Start (sector) End (sector) Size Code Name
1 2048 976895 476.0 MiB 8300 Linux filesystem
2 976896 8790015 3.7 GiB 8200 Linux swap
3 8790016 335544286 155.8 GiB 8300 Linux filesystem
4 34 2047 1007.0 KiB EF02 BIOS boot partition
5 22501064664 22501195742 64.0 MiB 8300 (Config drive is created at sector 22501064664 )
Then i have to change the sector size by one less for which config drive was created.
sgdisk --move-
***** Appears to have gone OK ****
Help would be appreciated.
Related branches
- Scott Moser (community): Approve
-
Diff: 12 lines (+1/-1)1 file modifiedbin/growpart (+1/-1)
Changed in cloud-utils: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
Changed in cloud-utils (Ubuntu): | |
status: | New → Confirmed |
importance: | Undecided → Medium |
Changed in cloud-utils: | |
status: | Confirmed → Fix Committed |
http:// bazaar. launchpad. net/~smoser/ ubuntu/ zesty/cloud- utils/pkg/ view/head: /bin/growpart# L292
commenting this out makes growpart work fine on >2TB GPT instance. Tested with 3T and 4T (but seems to work in general).
The mbr_max_512 shouldn't really be considered on a GPT disk, it's not applicable.