LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   can I move the /usr directory to another partition? (https://www.linuxquestions.org/questions/linux-newbie-8/can-i-move-the-usr-directory-to-another-partition-341470/)

walterbyrd 07-08-2005 11:07 PM

can I move the /usr directory to another partition?
 
I need to free up some space. I have a free linux partition. I don't have any data stored, the apps are taking up all the room.

Can I move the /usr directory to the free partition? The free partition is mounted on /temp. Can I just move everything in /usr to /temp. Then delete the old /usr and remane /temp /usr?

The only problem that I can forsee is that the fstab may not mount the partition with /usr on it soon enough.

btmiller 07-09-2005 12:41 AM

You can do this. It's best to do it in single user mode so nothing is actually relying on the /usr partition. You more or less have the procedure correct: move everything over and then edit /etc/fstab so that the new partition is mounted as /usr, then reboot.

Tinkster 07-09-2005 01:44 AM

Why boot? :)

init 1
move
umount /usr
edit fstab
mount /usr
init 3


Cheers,
Tink

abunsair 07-10-2005 04:31 AM

you can create a link

walterbyrd 07-10-2005 07:24 PM

Okay, I moved it.

It was a cinche. Nothing to it. I did a cp -r, instead of a mv; just to make sure I wouldn't lose anything if there was a problem.

After everything copied over, and the system worked just fine, I went ahead and deleted the original /usr directory, and freed up the space.

Thanks for the help.


All times are GMT -5. The time now is 10:43 PM.