Skip to content

It not possible to create persistent storage on a secondary nvme drive #1863

Description

@markVnl

A per subject.

To reproduce:
Create a setup one extra nvme drive for persistent storage.
Usually at initial setup storage is setup on the primary drive, if so delete it
Try to setup a new persistent storage on the secondary nvme drive

Expected behavior:
A persistent storage is created on the secondary nvme drive

Actual behavior:
It fails without an error message

Cause:
This fails because the partition naming scheme of a nvme is different from traditional block devices. The partition numbers have a p prefix. Below the offending line that assumes the newly created partition is called {device}1 on nvme’s it is {device}p1.

mkfs.ext4 -q -F -L ns_data "$device"1 >/dev/null

OT
This issue is a bit tongue in cheek as the same applies to EMMC’s and SD-Cards; which are as you know often used in arm devices. If this issue is addressed it would be nice to improve the workaround in ns-storage-setup-partition too:

if [[ "$dev" =~ ^/dev/nvme ]]; then

Here my proposal:
markVnl@21e952c

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

Status
ToDo 🕐

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions