0

My HDD is divided into two partitions and they are placed in the mnt folder under the root directory. And they are located inside new and windows respectively. Whenever I attempt to rename the second the second partition using root access in the terminal, I get an error message that states this: cannot move '/mnt/windows' to '/mnt/Main Volume': Device or resource busy. Let me share the full terminal code that I executed.

mv /mnt/windows /mnt/Main\ Volume
mv: cannot move '/mnt/windows' to '/mnt/Main Volume': Device or resource busy

Can anyone tell me why this is happening? And is there any other way to rename the partition folders?

2 Answers 2

3

Your partitions are not placed in /mnt, they are mounted there -- by mounting a partition (disk/volume...) to a specific location, you are saying "I want content of this device here" and you can't simply change it by renaming the mountpoint, you need to unmount the device and mount it again to a new location.

I assume your Windows partition is mounted during boot automatically thanks to a fstab entry, so you need to edit /etc/fstab and change the mountpoint there and either reboot or run sudo umount /mnt/windows and sudo mount -a to change the mountpoint without rebooting.

4
  • Thanks, it worked. But is there any other way to rename the device name that is showing to indicate the partition?
    – lone wolf
    Jan 27, 2021 at 14:09
  • I could rename the labels of the partition using ntfslabel. This tool is used to rename the ntfs partitions in linux distros. Thank you.
    – lone wolf
    Jan 27, 2021 at 14:23
  • Yes, you can change the label of NTFS but that won't change the mountpoint when using fstab. Jan 27, 2021 at 14:24
  • definitely. Using fstab, you need to manually set a mountpoint.
    – lone wolf
    Jan 27, 2021 at 14:28
0

It is because they are mount points. You can create the new mount point and bind mount to it (it will then be mounted twice). Then I think your can un-mount from the old mount point.

You should also update the the config files.

Note: /mnt is not intended for this use. It is for emergency sys-admin stuff. You should create a new mount points for your storage-devices.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .