The PARTLABEL is a property of the partition table (GPT), unrelated to partition content (any filesystem or lvm, luks, raid, etc.). Thus it's not overwritten when you mkfs
partition content.
If you are not using this value for anything, you can ignore it since it means nothing. Or, to avoid confusion, you can change it with any partition software of your choice.
Example with parted:
# parted /dev/loop0 print
Number Start End Size File system Name Flags
1 1049kB 94.4MB 93.3MB xfspart
# blkid /dev/loop0p1
/dev/loop0p1: PARTLABEL="xfspart" PARTUUID="a789cf0a-3a18-4b87-af2a-abfed6ca9028"
Change the PARTLABEL (partition name in parted) of partition 1 to something else:
# parted /dev/loop0 name 1 schnorrgiggl
Afterwards:
# blkid /dev/loop0p1
/dev/loop0p1: PARTLABEL="schnorrgiggl" PARTUUID="a789cf0a-3a18-4b87-af2a-abfed6ca9028"
# parted /dev/loop0 print
Number Start End Size File system Name Flags
1 1049kB 94.4MB 93.3MB schnorrgiggl
These names also appear under /dev/disk/by-partlabel
which can be a convenient way to refer to partition block devices. Consider meaningful names like grub, boot, root, home, ... instead of xfspart or extpart which could be anything at all. However, if you use duplicate labels on separate disks, it's unclear which one the partlabel will point to.
PARTUUIDs exists to avoid such naming scheme conflicts, and filesystem UUID is the safest way to refer to a filesystem by content (regardless of where it is stored), so for /etc/fstab
it's still best to use UUID=
instead of any LABEL=
, PARTLABEL=
, PARTUUID=
etc. alternatives.
fstab
but I suggest to remove this partition and create again and then format it with ext4. maybe there are some meta data in partition level. – binarysta May 28 '20 at 09:07