Partition uuid
Hello,
This MR intends to add the support for GPT partition UUID using the sfdisk
backend using the same work done for GPT partition label !4 (merged). The partition UUID is also known as PARTUUID
.
sfdisk
sets the partition UUID using the property uuid=
at creation; and it can be set later using the option --part-uuid
. The second way is chosen and a job is created to set it; see the first commit 1dde0357.
Note: Setting the partition UUID is not that useful as we can break the uniqueness of the partition identifiers, but it can be useful for tests, cloning or whatever funky cases. Because the option exists, let implement it, it is not harmful.
Also, kpmcore never know the UUID if it is generated automatically by the backend (sfdisk
in our case) at the creation of the partition.
The second commit e12f0ec3 fixes this. It adds the function getPartitionUUID()
to the backend that returns the UUID read using its internal tool and call it after the partition is created by the create-partition job.
Regards, Gaël