Skip to main content
replaced http://unix.stackexchange.com/ with https://unix.stackexchange.com/
Source Link

Given the partition device file /dev/sdh1, I need to find out the label of this device.

dmesg doesn't mention its label while GParted reveals that it is called H2N_SD:

gparted info about /dev/sdh

I need to build a way to be able to run something similar to

$ partlabel /dev/sdh1
H2N_SD

This question is nearly the opposite of getting device name & mount point from labelgetting device name & mount point from label.

Given the partition device file /dev/sdh1, I need to find out the label of this device.

dmesg doesn't mention its label while GParted reveals that it is called H2N_SD:

gparted info about /dev/sdh

I need to build a way to be able to run something similar to

$ partlabel /dev/sdh1
H2N_SD

This question is nearly the opposite of getting device name & mount point from label.

Given the partition device file /dev/sdh1, I need to find out the label of this device.

dmesg doesn't mention its label while GParted reveals that it is called H2N_SD:

gparted info about /dev/sdh

I need to build a way to be able to run something similar to

$ partlabel /dev/sdh1
H2N_SD

This question is nearly the opposite of getting device name & mount point from label.

Source Link
qubodup
  • 2.4k
  • 3
  • 21
  • 26

Get label of Linux storage partition device file

Given the partition device file /dev/sdh1, I need to find out the label of this device.

dmesg doesn't mention its label while GParted reveals that it is called H2N_SD:

gparted info about /dev/sdh

I need to build a way to be able to run something similar to

$ partlabel /dev/sdh1
H2N_SD

This question is nearly the opposite of getting device name & mount point from label.