NethServer / nethsecurity

NethSecurity image and build environment
https://www.nethsecurity.org/
Other
82 stars 5 forks source link

Can't use free space on nvme drive #584

Closed francio87 closed 1 week ago

francio87 commented 3 weeks ago

On a system with an NVME drive it's not possibile to use the empty space of the drive as log storage

Steps to reproduce

Expected behavior

The free space of the drive will be used to store the log of the system

Actual behavior

The operation fail and the storage is not visible anymore on the page

Further details

The partition get created successfully but not formatted and mounted, this issue is caused by the naming of the disk partition since they are seen by the system with the name (notice the "p" before the partition number):

 nvme0n1p1
 nvme0n1p2
 nvme0n1p3

This make the script fail the format and mount of the partition, since it expect the parition name to be device3 ie:

sdx3
vdx3
hdx3 

https://github.com/NethServer/nethsecurity/blob/c2233de1672002562967fe1e1f40b4540e7dbeab/packages/ns-storage/files/ns-storage-setup-partition#L34-L35

gsanchietti commented 2 weeks ago

Please note a similar issue is present when using an extra nvme disk, see https://github.com/NethServer/nethsecurity/blob/main/packages/ns-storage/files/ns-storage-setup-disk

gsanchietti commented 2 weeks ago

Let's ignore the nvme disk for now, it should not be a common usage scenario.

Test image: 23.05.3-ns.1.0.1-7-g8e71c34

Check the issue is not reproducible.

gsanchietti commented 2 weeks ago

Verified.