How to Rename a Drive/Partition in Centos

Rename a Drive/Partition in Centos Operating System. This post is not for linux expert . Rename a partition in linux may be required in some cases like this

  • Suppose you have create / (root) , Swap  and /home at the time of installing Centos . But later u know that you should name /home as /vz .*

Now see the steps to rename Partition in Centos . Don’t use ‘ ” ‘ inverted comma in command.

  1. you have to unmount the parition 1st you want to rename. You should run this command to unmount required partition to rename in centos. ” umount /home” Here /home is the partition I want to rename.
  2. Run this command ” mountpoint /home &>/dev/null || mv /home /vz “. Replace home with your required partition to rename and /vz with the new name you want to set.
  3. Now you have run this command ” vi /etc/fstab” . Edit fstab file . you can see /home in the file just replace that with the new name.
  4. We are almost done. Run this command ” mount /vz” to mound the partition.

If you have any query with renaming partition in centos please comment.

Share this post

PinIt
submit to reddit

Leave a Reply

scroll to top