[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Out of room on /usr partition



Ian T. wrote:

Hi there.
I have run out of room on my /usr/bin partition (95%). I have a couple of hard drives in that box but Debian resides on a 10 gig scsi. The box is an old PII with 256 RAM.

I have room elsewhere but searching didn't turn up any recipes for linking or otherwise telling the system to use some other more roomy areas when it needs to write to /usr/bin.

I believe the best way to solve this would be to create a new partition, move the contents of /usr/bin there, and then mount it as the new /usr/bin and update /etc/fstab. But if you have room on an existing partition, you could probably use that. I've done this before, and it worked quite well (although it was only website data, and wasn't as important as /usr/bin). All I did was create a directory somewhere on the drive that had more room, copy all the data over there and then create a symlink in the original location. e.g., if you want to move /usr/bin to a location in /var, say '/var/fake-bin':

mkdir /var/fake-bin
mv /usr/bin/* /var/fake-bin/
rmdir /usr/bin
ln -s /var/fake-bin /usr/bin

Now, you'd probably want to do this in single-user mode so that there aren't any processes that will try to access /usr/bin while you're doing this. I've checked, and all the binaries used in those steps reside in /bin, so that won't cause any problems... Of course, if anything goes wrong, it should be just as easy to move all the files back and call the whole thing off.

Good luck! :-)

Chad.



Reply to: