You are not logged in.

#1 2006-12-11 08:28:09

Shagbag
Member
Registered: 2006-10-25
Posts: 259

Can I resize my Arch partition without hosing my install?

I switched to Arch from Ubuntu about 2 months ago.  At the time, I created a 25GB partition for the install.  I'm now finding I'm using Arch all the time and want to keep it as my main distro.  The problem is that I want to add another 20GB to my partition but, as I've spent so much time configuring Arch to get it the way I want it, I don't want to waste this effort by having to re-install from base.

Can I resize my existing 25GB partition to 45GB without hosing my existing Arch install?

Offline

#2 2006-12-11 08:50:06

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: Can I resize my Arch partition without hosing my install?

If you are lucky your install should be fine.

But man, why would you need so much space. I hardly touch 10gigs on my root. If documents, music, videos and other big things are taking up space why don't you try making a new partition for holding those files.

Unless you have 45gigs of installed software which is a lot. O_o

Offline

#3 2006-12-11 08:59:20

Zoranthus
Member
From: muc
Registered: 2006-11-22
Posts: 166

Re: Can I resize my Arch partition without hosing my install?

Depending on your partitioning situation (what sits where on your hdd), you should be able to shrink your other partition, create a new ext2 from the freed up space and then mount it to where you want - shouldn't make much of a difference.

Resizing ext2 partitions doesn't seem to be supported by my favourite partitioning program.. don't know about others:  http://qtparted.sourceforge.net/features.en.html

Offline

#4 2006-12-11 10:13:25

ploxiln
Member
Registered: 2006-10-27
Posts: 50

Re: Can I resize my Arch partition without hosing my install?

Since you can't resize your arch partition while you're using it, I would suggest using the gparted live cd:

http://gparted.sourceforge.net/livecd.php

I've used it a few times for resizing and moving ntfs, ext2/3, and reiserfs partitions, and it... works.

Offline

#5 2006-12-11 10:16:34

chrismortimore
Member
From: Edinburgh, UK
Registered: 2006-07-15
Posts: 655

Re: Can I resize my Arch partition without hosing my install?

To be honest, I find using those tools takes forever.  If I were you, I'd just backup your existing Arch installation, repartition, and put it back.  It's probably a lot quicker.  Mind you, it does depend on how confident you are about doing that.  And it also depends on whether you have something to back up to (DVDs, an external hard drive, that kind of thing).


Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB

Offline

#6 2006-12-11 12:30:03

xterminus
Member
From: Tacoma, WA, USA, Earth, Sol, M
Registered: 2005-10-30
Posts: 93

Re: Can I resize my Arch partition without hosing my install?

chrismortimore wrote:

To be honest, I find using those tools takes forever.  If I were you, I'd just backup your existing Arch installation, repartition, and put it back.  It's probably a lot quicker.  Mind you, it does depend on how confident you are about doing that.  And it also depends on whether you have something to back up to (DVDs, an external hard drive, that kind of thing).

If you are going to repartition, you might as well start using LVM.  That way in the future you'll be able to repartition and resize without all the destruction.

Offline

#7 2006-12-11 18:02:31

Shagbag
Member
Registered: 2006-10-25
Posts: 259

Re: Can I resize my Arch partition without hosing my install?

Of course!  LVM!  OMG, why didn't I look into that BEFORE I installed Arch?  Probably because it was one of those things I'd heard about but never really took any time to investigate.  It's coming back to bite me now sad

Is it too late for me to set up some logical volumes or is LVM the kind of thing done only at install?

Offline

#8 2006-12-11 18:05:09

chrismortimore
Member
From: Edinburgh, UK
Registered: 2006-07-15
Posts: 655

Re: Can I resize my Arch partition without hosing my install?

Shagbag wrote:

Is it too late for me to set up some logical volumes or is LVM the kind of thing done only at install?

You can do it any time you like.  It is easier at install, but if you make the partitions, you can just move everything over from the old partitions to their LVM counterparts.


Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB

Offline

#9 2006-12-11 19:05:18

Shagbag
Member
Registered: 2006-10-25
Posts: 259

Re: Can I resize my Arch partition without hosing my install?

Thanks.  That still sounds a bit cryptic to a n00b like me but I'm definitely going to do some reading up on it.  It sounds like the panacea to my laptop storage problems.

Offline

#10 2006-12-11 19:12:20

chrismortimore
Member
From: Edinburgh, UK
Registered: 2006-07-15
Posts: 655

Re: Can I resize my Arch partition without hosing my install?

Shagbag wrote:

Thanks.  That still sounds a bit cryptic to a n00b like me but I'm definitely going to do some reading up on it.  It sounds like the panacea to my laptop storage problems.

Here's an example.  Say you want swap and /home on an lvm partition, here is how you'd go about it.

Make a partition of type 8E (LVM) using fdisk, cfdisk, etc.  Lets call it /dev/hda4 for this example.
Run "lvm pvcreate /dev/hda4" to make the physical volume
Run "lvm vgcreate lvm /dev/hda4" to make a volume group called "lvm"
Run "lvm lvcreate -L1G -nswap lvm" to make a 1G logical volume called "swap"
Run "lvm lvcreate -L5G -nhome lvm" to make a 5G logical volume called "home".

Now, "mkswap /dev/lvm/swap" and "swapon /dev/lvm/swap" will get the swap partition up and running.

For /home, make a filesystem like so: "mke2fs -j -L home /dev/lvm/home".
Make a mount point: "mkdir -p /mnt/home"
Mount away: mount /dev/lvm/home /mnt/home
And move everything over: "cp -av /home/* /mnt/home/"

And now you just edit your fstab so it using /dev/lvm/home and /dev/lvm/swap as needed.

Simple!  Isn't it?

Oh yeah, and remember to install lvm2...


Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB

Offline

#11 2006-12-11 23:22:30

RobF
Member
Registered: 2006-10-10
Posts: 157

Re: Can I resize my Arch partition without hosing my install?

I can't comment on using LVM but perhaps the simplest way to do what you want to accomplish would be to back up your current Arch partition using partimage, e.g. onto an external USB HDD or an unused partition of your internal drive(s) or onto DVD's, then repartition the internal drive using the GParted live CD, and then restore your Arch system from the partimage backup.

Or you could keep your present 25 GB partition as a / (root) partition and clone the /home directory over to the empty new 20 GB partition, using partimage, and once you have satisfied yourself that everything is working wipe out the /home partition in the old 25 GB partition.

BTW, I don't recommend QtParted at all; it has let me down quite a few times whereas the GParted live CD has never let me down.

Robert

Offline

Board footer

Powered by FluxBB