Turned out that, in filesystem controllers, it only picks all disks (without compound devices like RAID), so the layout mode only applies to simple disk devices, not compound devices like RAID or LVM. This I guess is to prevent some issues like installing into non-bootable RAID, setting up LVM over LVM for encryption setup, etc.
I've made the changes in the attachment in order to let auto layout detect the RAID disks, without considering about the other compound cases, therefore this patch is only a reference of my discovery and is not for production.
For reference, this is the result I got from Intel VROC from the patched subiquity to list all devices before match:
2024-03-06 01:18:43,971 INFO subiquity.server.controllers.filesystem:1418 all devices.....
2024-03-06 01:18:43,971 INFO subiquity.server.controllers.filesystem:1419 [
Raid(name='md125', raidlevel='raid0', devices={}, spare_devices={}, preserve=True, container=raid-md127, id='raid-md125'),
Raid(name='md127', raidlevel='container', devices=[disk-nvme2n1, disk-nvme3n1], spare_devices=[], preserve=True, metadata='imsm', id='raid-md127'),
Raid(name='md126', raidlevel='container', devices=[disk-nvme4n1, disk-nvme6n1], spare_devices=[], preserve=True, metadata='imsm', id='raid-md126'),
Disk(serial='KXG50ZNV256G_NVMe_TOSHIBA_256GB_77HS107ITNTT_1', wwn='eui.000000000000001000080d02002ac166', nvme_controller=nvme-controller-nvme6, path='/dev/nvme6n1', preserve=True, id='disk-nvme6n1', type='disk'),
Disk(ptable='gpt', serial='Micron_3400_NVMe_512GB_21122E618437_1', wwn='eui.000000000000000100a075212e618437', nvme_controller=nvme-controller-nvme5, path='/dev/nvme5n1', preserve=True, id='disk-nvme5n1', type='disk'),
Disk(serial='PC_SN730_NVMe_WDC_256GB_20333A801561_1', wwn='eui.e8238fa6bf530001001b448b49132209', nvme_controller=nvme-controller-nvme2, path='/dev/nvme2n1', preserve=True, id='disk-nvme2n1', type='disk'),
Disk(serial='PC_SN730_NVMe_WDC_256GB_20333A802075_1', wwn='eui.e8238fa6bf530001001b448b49132a14', nvme_controller=nvme-controller-nvme3, path='/dev/nvme3n1', preserve=True, id='disk-nvme3n1', type='disk'),
Disk(ptable='gpt', serial='PC_SN810_NVMe_WDC_512GB_23092V800479', path='/dev/sda', preserve=True, id='disk-sda', type='disk'),
Disk(ptable='gpt', serial='PM9C1a_Samsung_256GB_______S75JNE0W700023_1', wwn='eui.002538a7310004c9', nvme_controller=nvme-controller-nvme0, path='/dev/nvme0n1', preserve=True, id='disk-nvme0n1', type='disk'),
Disk(ptable='gpt', serial='PM9C1a_Samsung_256GB_______S75JNE0W700056_1', wwn='eui.002538a7310004ea', nvme_controller=nvme-controller-nvme1, path='/dev/nvme1n1', preserve=True, id='disk-nvme1n1', type='disk'),
Disk(serial='THNSN5256GPUK_NVMe_TOSHIBA_256GB_X65S11JQT18T_1', wwn='eui.00080d0200113fc5', nvme_controller=nvme-controller-nvme4, path='/dev/nvme4n1', preserve=True, id='disk-nvme4n1', type='disk')
]
Turned out that, in filesystem controllers, it only picks all disks (without compound devices like RAID), so the layout mode only applies to simple disk devices, not compound devices like RAID or LVM. This I guess is to prevent some issues like installing into non-bootable RAID, setting up LVM over LVM for encryption setup, etc.
I've made the changes in the attachment in order to let auto layout detect the RAID disks, without considering about the other compound cases, therefore this patch is only a reference of my discovery and is not for production.
For reference, this is the result I got from Intel VROC from the patched subiquity to list all devices before match: server. controllers. filesystem: 1418 all devices..... server. controllers. filesystem: 1419 [ raid-md127, id='raid-md125'), 'container' , devices= [disk-nvme2n1, disk-nvme3n1], spare_devices=[], preserve=True, metadata='imsm', id='raid-md127'), 'container' , devices= [disk-nvme4n1, disk-nvme6n1], spare_devices=[], preserve=True, metadata='imsm', id='raid-md126'), 'KXG50ZNV256G_ NVMe_TOSHIBA_ 256GB_77HS107IT NTT_1', wwn='eui. 000000000000001 000080d02002ac1 66', nvme_controller =nvme-controlle r-nvme6, path='/ dev/nvme6n1' , preserve=True, id='disk-nvme6n1', type='disk'), 'Micron_ 3400_NVMe_ 512GB_21122E618 437_1', wwn='eui. 000000000000000 100a075212e6184 37', nvme_controller =nvme-controlle r-nvme5, path='/ dev/nvme5n1' , preserve=True, id='disk-nvme5n1', type='disk'), 'PC_SN730_ NVMe_WDC_ 256GB_20333A801 561_1', wwn='eui. e8238fa6bf53000 1001b448b491322 09', nvme_controller =nvme-controlle r-nvme2, path='/ dev/nvme2n1' , preserve=True, id='disk-nvme2n1', type='disk'), 'PC_SN730_ NVMe_WDC_ 256GB_20333A802 075_1', wwn='eui. e8238fa6bf53000 1001b448b49132a 14', nvme_controller =nvme-controlle r-nvme3, path='/ dev/nvme3n1' , preserve=True, id='disk-nvme3n1', type='disk'), 'PC_SN810_ NVMe_WDC_ 512GB_23092V800 479', path='/dev/sda', preserve=True, id='disk-sda', type='disk'), 'PM9C1a_ Samsung_ 256GB__ _____S75JNE0W70 0023_1' , wwn='eui. 002538a7310004c 9', nvme_controller =nvme-controlle r-nvme0, path='/ dev/nvme0n1' , preserve=True, id='disk-nvme0n1', type='disk'), 'PM9C1a_ Samsung_ 256GB__ _____S75JNE0W70 0056_1' , wwn='eui. 002538a7310004e a', nvme_controller =nvme-controlle r-nvme1, path='/ dev/nvme1n1' , preserve=True, id='disk-nvme1n1', type='disk'), 'THNSN5256GPUK_ NVMe_TOSHIBA_ 256GB_X65S11JQT 18T_1', wwn='eui. 00080d0200113fc 5', nvme_controller =nvme-controlle r-nvme4, path='/ dev/nvme4n1' , preserve=True, id='disk-nvme4n1', type='disk')
2024-03-06 01:18:43,971 INFO subiquity.
2024-03-06 01:18:43,971 INFO subiquity.
Raid(name='md125', raidlevel='raid0', devices={}, spare_devices={}, preserve=True, container=
Raid(name='md127', raidlevel=
Raid(name='md126', raidlevel=
Disk(serial=
Disk(ptable='gpt', serial=
Disk(serial=
Disk(serial=
Disk(ptable='gpt', serial=
Disk(ptable='gpt', serial=
Disk(ptable='gpt', serial=
Disk(serial=
]