Re: [ILUG] Disk Space Crisis.

From: Niall O Broin (niall at domain magicgoeshere.com)
Date: Tue 25 Jul 2000 - 20:50:38 IST


On Tue, Jul 25, 2000 at 08:08:09PM +0100, Robert Sweetnam wrote:

> I'm trying to install some new software on my RH6.1 machine. but I'm
> running into a bit of difficulty because my / partition is full!!
> I have the disk partitioned as follows:
>
> Filesystem 1k-blocks Used Available Use% Mounted on
> /dev/hda1 1011928 972612 0 100% /
> /dev/hda6 1011928 132 960392 0% /export/home
> /dev/hda5 3028080 616236 2258024 21% /opt
> /dev/hda7 885436 20 840436 0% /spare
> /dev/hdc 656574 656574 0 100% /mnt/cdrom
>
> Basically I was wondering if there is a quick way that I can resize the
> partitions or is it a bit of a nightmare!.

There's no quick answer, but there is an answer which doesn't involve
backing up to tape and remaking your partitions. The idea is to use hda7 for
/opt and then reuse hda6 for /. Steps would be

init 1 # so that as little as possible is running

cd /opt

find . -xdev | cpio -pmd /spare # copy /opt to its new location

mkdir OLDOPT # keep old /opt stuff for the moment, just to be sure . .

mv * OLDOPT # Ignore error message

mv OLDOPT/lost+found .

cd /

find . -xdev | cpio -pmd /opt # copy / to its new location

Now you'll need to edit /opt/etc/fstab because in the new world order, / is
on hda5 and /opt is on hda7 and /spare is temporarily gone. Booting is
another issue. LILO as shipped with RH6.1 won't boot from hda6. You can get
over that pro tem by using a boot floppy. Long term solutions would be

i) make a separate partition for /boot on hda1 - 20M should be loads, and then
you could use the rest of hda1 for /spare

ii) install the new version of LILO which can boot from beyond the 1024 cylinder
barrier, with appropriate hardware.

This whole thing illustrates the rightness of the one big root filesystem principal.

Regards,

Niall



This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:06:59 GMT