Activity log for bug #1882809

Date Who What changed Old value New value Message
2020-06-09 16:14:35 David Andruczyk bug added bug
2020-11-30 10:36:19 Adam Collard description I've been fighting with an issue when creating Teh following configuration: 4 or more devices in a RAID10 configuration RAID10 device partitioned into two partitions. Two separate volume grouts created on the separate partitions. When using both MAAS and the python-libmaas API to configure the machine, if I use the available size for the RAID device when partitioning it, it results in a build failure EVERY TIME. Creating the partitions with some free space on the device (the amount needed seems to depend on the size of the device, the bigger device, the more you seem to set aside (but a fixed percentage of the full disk) allows the build to succeed, so there's a math problem within MAAS. I deployed a machine using an undersized partitioning of the RAID10 device which works. Using fdisk to show the disk, I get root@use1-maas-test-17:~# fdisk -l /dev/md2 Disk /dev/md2: 10.9 TiB, 12002065907712 bytes, 23441534976 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 524288 bytes / 1048576 bytes Disklabel type: gpt Disk identifier: 5895A0FD-7CB8-4526-862C-E0515D1C4B68 Device Start End Sectors Size Type /dev/md2p1 2048 7812491263 7812489216 3.7T Linux filesystem /dev/md2p2 7812491264 22660556799 14848065536 6.9T Linux filesystem Querying MAAS for the same block device shows: { "size": 12002336309248, "block_size": 512, There's a discrepancy there of 270401536 bytes (maas thinks the device is bigger than it really is by 270401536 bytes (270MB) in this case of a RAID10 or 4 6T drives) and if you let it use the full space in the gui or via the API it results in a failure during partitioning (AND in most cases NO LOG EITHER back to the maas GUI). I'm also noticing discrepancies on the physical device partitions The physical device size matches between hte OS and maas, but the partition sizes do NOT. /dev/sdd Command (? for help): p Disk /dev/sdd: 11721045168 sectors, 5.5 TiB Logical sector size: 512 bytes Disk identifier (GUID): 80D01024-7A50-402C-8F1C-D1F7D78139F9 Partition table holds up to 128 entries First usable sector is 34, last usable sector is 11721045134 Partitions will be aligned on 2048-sector boundaries Total free space is 11373 sectors (5.6 MiB) Number Start (sector) End (sector) Size Code Name 1 2048 4095 1024.0 KiB EF02 2 4096 11721035775 5.5 TiB 8300 Command (? for help): { "firmware_version": "T7J0", "size": 6001175126016, "block_size": 4096, "available_size": 0, "uuid": null, "id": 7486, "serial": "5000cca24dc83007", "name": "sdd", "filesystem": null, "partition_table_type": "GPT", "partitions": [ { "uuid": "2c1b90c8-c289-476e-82e5-7d2e17f6cacd", "size": 6001168220160, "bootable": false, "tags": [], "id": 5188, "filesystem": { "fstype": "raid", "label": null, "uuid": "4f7d7e3a-3951-4ca3-9bdd-e217e99df9f5", "mount_point": null, "mount_options": null }, "device_id": 7486, "path": "/dev/disk/by-dname/sdd-part2", "used_for": "Active raid-10 device for md2", "type": "partition", "system_id": "ydrxfb", "resource_uri": "/MAAS/api/2.0/nodes/ydrxfb/blockdevices/7486/partition/5188" } ], "storage_pool": null, "tags": [ "rotary", "allocated" ], "id_path": "/dev/disk/by-id/scsi-SATA_HGST_HUS726060AL_NCGL0B4Z", "path": "/dev/disk/by-dname/sdd", "used_for": "GPT partitioned with 1 partition", "model": "HGST_HUS726060AL", "type": "physical", "used_size": 6001174511616, "system_id": "ydrxfb", "resource_uri": "/MAAS/api/2.0/nodes/ydrxfb/blockdevices/7486/" }, so the disk size from the OS is 6001175126016 bytes which matches what maas says for "size" However the size of partitions for that device don't line up quite right. I've been fighting with an issue when creating the following configuration: 4 or more devices in a RAID10 configuration RAID10 device partitioned into two partitions. Two separate volume grouts created on the separate partitions. When using both MAAS and the python-libmaas API to configure the machine, if I use the available size for the RAID device when partitioning it, it consistently results in a build failure. Creating the partitions with some free space on the device (the amount needed seems to depend on the size of the device, the bigger device, the more you seem to set aside (but a fixed percentage of the full disk) allows the build to succeed, so there's a math problem within MAAS. I deployed a machine using an undersized partitioning of the RAID10 device which works. Using fdisk to show the disk, I get root@use1-maas-test-17:~# fdisk -l /dev/md2 Disk /dev/md2: 10.9 TiB, 12002065907712 bytes, 23441534976 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 524288 bytes / 1048576 bytes Disklabel type: gpt Disk identifier: 5895A0FD-7CB8-4526-862C-E0515D1C4B68 Device Start End Sectors Size Type /dev/md2p1 2048 7812491263 7812489216 3.7T Linux filesystem /dev/md2p2 7812491264 22660556799 14848065536 6.9T Linux filesystem Querying MAAS for the same block device shows: {                 "size": 12002336309248,                 "block_size": 512, There's a discrepancy there of 270401536 bytes (maas thinks the device is bigger than it really is by 270401536 bytes (270MB) in this case of a RAID10 or 4 6T drives) and if you let it use the full space in the gui or via the API it results in a failure during partitioning (AND in most cases NO LOG EITHER back to the maas GUI). I'm also noticing discrepancies on the physical device partitions The physical device size matches between the OS and maas, but the partition sizes do NOT. /dev/sdd Command (? for help): p Disk /dev/sdd: 11721045168 sectors, 5.5 TiB Logical sector size: 512 bytes Disk identifier (GUID): 80D01024-7A50-402C-8F1C-D1F7D78139F9 Partition table holds up to 128 entries First usable sector is 34, last usable sector is 11721045134 Partitions will be aligned on 2048-sector boundaries Total free space is 11373 sectors (5.6 MiB) Number Start (sector) End (sector) Size Code Name    1 2048 4095 1024.0 KiB EF02    2 4096 11721035775 5.5 TiB 8300 Command (? for help): {                 "firmware_version": "T7J0",                 "size": 6001175126016,                 "block_size": 4096,                 "available_size": 0,                 "uuid": null,                 "id": 7486,                 "serial": "5000cca24dc83007",                 "name": "sdd",                 "filesystem": null,                 "partition_table_type": "GPT",                 "partitions": [                     {                         "uuid": "2c1b90c8-c289-476e-82e5-7d2e17f6cacd",                         "size": 6001168220160,                         "bootable": false,                         "tags": [],                         "id": 5188,                         "filesystem": {                             "fstype": "raid",                             "label": null,                             "uuid": "4f7d7e3a-3951-4ca3-9bdd-e217e99df9f5",                             "mount_point": null,                             "mount_options": null                         },                         "device_id": 7486,                         "path": "/dev/disk/by-dname/sdd-part2",                         "used_for": "Active raid-10 device for md2",                         "type": "partition",                         "system_id": "ydrxfb",                         "resource_uri": "/MAAS/api/2.0/nodes/ydrxfb/blockdevices/7486/partition/5188"                     }                 ],                 "storage_pool": null,                 "tags": [                     "rotary",                     "allocated"                 ],                 "id_path": "/dev/disk/by-id/scsi-SATA_HGST_HUS726060AL_NCGL0B4Z",                 "path": "/dev/disk/by-dname/sdd",                 "used_for": "GPT partitioned with 1 partition",                 "model": "HGST_HUS726060AL",                 "type": "physical",                 "used_size": 6001174511616,                 "system_id": "ydrxfb",                 "resource_uri": "/MAAS/api/2.0/nodes/ydrxfb/blockdevices/7486/"             }, so the disk size from the OS is 6001175126016 bytes which matches what maas says for "size" However the size of partitions for that device don't line up quite right.
2021-06-29 08:39:31 Alberto Donato maas: importance Undecided Medium
2021-06-29 08:39:33 Alberto Donato maas: status New Triaged
2023-01-19 09:49:52 Jerzy Husakowski maas: status Triaged Incomplete
2023-03-21 04:17:16 Launchpad Janitor maas: status Incomplete Expired