I'd like to mount a folder on another partition (/dev/sda) named /usr to my local /usr, but I failed.
Here's my attempt:
Use a live CD and select try ubuntu.
Mount the partition using
sudo mount -s /dev/sda /d
sudo mkdir /d/usr
, and copy the content to it usingrsync -avH usr /d/usr
remove the original /usr folder
rm -rf usr
add this line to etc/fstab:
UUID=74e1363e-5493-4522-977f-c267751e9d1a /d ext4 defaults 0 2
in which the 74e.... is the uuid of the partition
add a symlink using
sudo ln -s /d/usr .
restart the computer.
this doesn't work for me and the computer can't start normally.
how can I solve this and mount a folder to /usr correctly?