Forrest logo
back to the e2label tool

e2label:tldr:9701c

e2label: Change the volume label on a specific ext partition.
$ e2label ${-dev-sda1} "${label_name}"
try on your machine

This command is used to change or set the label of a filesystem on the device /dev/sda1 to a given ${label_name}.

Breaking it down:

  • e2label is the command used to set or change the label of a filesystem.
  • ${-dev-sda1} refers to the device /dev/sda1 on which the filesystem label needs to be modified. ${-dev-sda1} is potentially a typo or an incorrect usage. It should be corrected to /dev/sda1.
  • "${label_name}" is the new label that will be assigned to the filesystem on /dev/sda1. ${label_name} should be replaced with the desired label name. Make sure to enclose the label name in quotes if it contains spaces or special characters.

The corrected version of the command would be:

e2label /dev/sda1 "new_label"

This would change the label of the filesystem on /dev/sda1 to "new_label".

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the e2label tool