Click to See Complete Forum and Search --> : repartitioning


spacetask
04-16-2001, 05:13 PM
I have a 25 GB partition (hda7) that I'm using for /home. It only has about 15 MB of files on it. I would like to take 2 GB from the unused space on that partition and make it into a new partition for /var.

Is this possible? Should I even try it? What program do I need?

[ 16 April 2001: Message edited by: spacetask ]

[ 16 April 2001: Message edited by: spacetask ]

just me
04-16-2001, 06:14 PM
I'm a way newbie and know nothing, but I read this on linuxtoday.com which might be of some help.

Regards,
SML

http://linuxtoday.com/news_story.php3?ltsn=2001-04-15-008-20-PS-HL-SW

[ 16 April 2001: Message edited by: just me ]

bdg1983
04-17-2001, 06:11 AM
Check out the Linuxnewbie NHF's on partitioning and other related topics.

Pierre Lambion
04-17-2001, 06:32 AM
The easisest would be to
1/ copy the files thar are on hda7 to another partition (the root one for instance),
2/ then fdisk or cfdisk, delete hda7
3/ create two partitions from the free space (hda7 and hda8 maybe, depending on your existing ones)
4/ specify those two partition in /etc/fstab

If you know fdisk/cfdisk and fstab it sould be safe to do. And it is much recommended to use a separate partition for /var.

Pierre

spacetask
04-27-2001, 10:51 PM
Thanks for the advice.

I did as the last post suggested. I copied hda7 files elsewhere. Deleted hda7. Made two new partitions, hda7 and hda8, of the desired size. Wrote the data to the boot record, but I got an error like:
Writing data to boot record.
Re-read boot record failed. Reboot to load new boot record.
(I tried this with fdisk and then with cfdisk).

When I reboot, fsck gives me a warning like: /dev/hda7 is #### size, but the boot record says it should be the old size.

My HD is a Maxtor with that EZ-BIOS program on it. I suspect that has something to do with it, but I don't know how to get around it.

Craig McPherson
04-27-2001, 11:43 PM
You should have used ext2resize. It's much safer, and doesn't require you to move a huge amount of data around. I've been reading to write a NHF on it here in the next few days, but until then, you can just read the man page for it: it's pretty self-explanatory.

spacetask
04-28-2001, 06:20 PM
That works. Thank you.