Disk partitioning failing during Deployment on NVME storage device

Attempting to Deploy Ubuntu 20.04 on an HPE DL20 Gen10 with an NVMe drive fails with the following error:

An error occured handling 'nvme0n1-part1': OSError - could not get path to dev from kname: nvme0n1p1
        finish: cmd-install/stage-partitioning/builtin/cmd-block-meta: FAIL: configuring partition: nvme0n1-part1

@zrsolis, this error can occur when there’s an accent in the pathname. can you share some more information about what you were doing, like logs, inputs, command, etc?

Did you ever find a solution? I have the same issue on an ubuntu (mate) 24.04.

In the autoinstall.yaml storage section there is this entry:

storage:
  layout:
    name: lvm
    password: LUKS_PASSPHRASE
    match:
      ssd: yes

Just what is recommended here: https://discourse.ubuntu.com/t/automated-server-installer-config-file-reference/16613

Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         get_path_to_storage_volume for volume partition-0({'device': 'disk-nvme0n1', 'size': 1127219200, 'wipe': 'superblock', 'flag': 'boot', 'number': 1, 'preserve': False, 'grub_device': True, 'offset': 1048576, 'path': '/dev/nvme0n1p1', 'id': 'partition-0', 'type': 'partition'})
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         get_path_to_storage_volume for volume disk-nvme0n1({'ptable': 'gpt', 'serial': 'SAMSUNG_MZVLB2T0HALB-000L7_S4GCNF0Rxxxxxx_1', 'wwn': 'eui.0025388111b10757', 'nvme_controller': 'nvme-controller-nvme0', 'path': '/dev/nvme0n1', 'wipe': 'superblock-recursive', 'preserve': False, 'name': '', 'grub_device': False, 'id': 'disk-nvme0n1', 'type': 'disk'})
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         /dev/nvme0n1 is multipath device member? False
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         /dev/nvme0n1 is multipath device member? False
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         /dev/nvme0n1 is multipath device member? False
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         found candidate disks [{'/dev/nvme0n1'}, {'/dev/nvme0n1'}, {'/dev/nvme0n1'}]
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         Running command ['partprobe', '/dev/nvme0n1'] with allowed return codes [0, 1] (capture=False)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         Running command ['udevadm', 'settle'] with allowed return codes [0] (capture=False)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         TIMED udevadm_settle(): 0.082
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         devsync happy - path /dev/nvme0n1 now exists
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         return volume path /dev/nvme0n1
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         An error occured handling 'partition-0': OSError - could not get path to dev from kname: nvme0n1p1
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         finish: cmd-install/stage-partitioning/builtin/cmd-block-meta: FAIL: configuring partition: partition-0
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         TIMED BLOCK_META: 5.387
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         finish: cmd-install/stage-partitioning/builtin/cmd-block-meta: FAIL: curtin command block-meta
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         Traceback (most recent call last):
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/commands/main.py", line 202, in main
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             ret = args.func(args)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/log.py", line 97, in wrapper
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             return log_time("TIMED %s: " % msg, func, *args, **kwargs)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/log.py", line 79, in log_time
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             return func(*args, **kwargs)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/commands/block_meta.py", line 127, in block_meta
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             return meta_custom(args)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/commands/block_meta.py", line 2278, in meta_custom
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             handler(command, storage_config_dict, context)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/commands/block_meta_v2.py", line 539, in partition_handler_v2
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             context.id_to_device[info['id']] = get_path_to_storage_volume(
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/commands/block_meta.py", line 588, in get_path_to_storage_volume
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             volume_path = block.kname_to_path(partition_kname)
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:           File "/snap/ubuntu-desktop-bootstrap/171/lib/python3.10/site-packages/curtin/block/__init__.py", line 118, in kname_to_path
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:             raise OSError('could not get path to dev from kname: {}'.format(kname))
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         OSError: could not get path to dev from kname: nvme0n1p1
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         could not get path to dev from kname: nvme0n1p1
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]:         
Dec 12 12:05:37 ubuntu-mate subiquity_log.4450[7074]: Stderr: ''

I solved it. This is working for me now:

  storage:
    layout:
      name: lvm
      sizing-policy: all
      password: LUKS_PASSPHRASE
      match:
        size: largest