You are not logged in.

#1 2009-01-19 00:49:35

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

[Solved] Want to resize /home partition, is this possible, how?

Hi,

I installed arch linux and I have about 100gb dedicated to me /home partition...only about 1gb used, and I want to shrink it down lots. Is this possible? Whenever I try, it tells me the partition is already mounted, and it wont let me unmount.

Last edited by playdafunkimuzic (2009-01-19 05:35:17)

Offline

#2 2009-01-19 01:02:38

LTSmash
Member
From: Aguascalientes - Mexico
Registered: 2008-01-02
Posts: 348
Website

Re: [Solved] Want to resize /home partition, is this possible, how?

You can use a Live-cd and repartition from there, or you can boot arch directly to root session, that way you can umount yout /home and repartition


Proud Ex-Arch user.
Still an ArchLinux lover though.

Currently on Kubuntu 9.10

Offline

#3 2009-01-19 01:06:33

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

How do i boot directly into root session? That's what I wanted smile

Offline

#4 2009-01-19 01:11:16

LTSmash
Member
From: Aguascalientes - Mexico
Registered: 2008-01-02
Posts: 348
Website

Re: [Solved] Want to resize /home partition, is this possible, how?

playdafunkimuzic wrote:

How do i boot directly into root session? That's what I wanted smile

Change your /etc/inittab to start in console mode and reboot... another solution would be to lazy umount /home

umount -l /home

And then kill any session opened by pressing Alt - Ctrl - Pet Sys - E...


Proud Ex-Arch user.
Still an ArchLinux lover though.

Currently on Kubuntu 9.10

Offline

#5 2009-01-19 01:22:50

archlinuxsagi
Member
Registered: 2008-09-12
Posts: 259

Re: [Solved] Want to resize /home partition, is this possible, how?

LTSmash wrote:

Change your /etc/inittab to start in console mode and reboot.

or starting init 1 at grub.

Offline

#6 2009-01-19 02:44:52

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Okay, so i'm at the resizing stage in 'parted'

i type 'resize 4' since it's the 4th partition

currently it begins at 23.7GB, and ends at 160GB

i want to change it to, let's say, 100GB

it says, Start? ..
what should i put there, and what do i put for end? thanks.

Offline

#7 2009-01-19 02:47:48

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

When I do either:

"resize 4 23.7 100" or "resize 4 23.7 100 ext2" I get : Error: File system has an incompatible feature enabled

Offline

#8 2009-01-19 03:22:27

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Okay, i just decided to use gparted...and I was able to shrink that partition, now with the new space i want to create an ntfs partition for windows (need 1 windows program sad ) but it says i can only have 4 primary partitions. what do i do?

Offline

#9 2009-01-19 03:27:14

weasel8
Member
Registered: 2008-12-15
Posts: 149

Re: [Solved] Want to resize /home partition, is this possible, how?

playdafunkimuzic wrote:

Okay, i just decided to use gparted...and I was able to shrink that partition, now with the new space i want to create an ntfs partition for windows (need 1 windows program sad ) but it says i can only have 4 primary partitions. what do i do?

You will need to either consolidate Linux into 3 partitions or use logical partitions. Logical partitions are contained in a certain type of partition called an extended partition, which allows you to have many more partitions than only 4.

As far as I know, and I could be wrong, Windows doesn't like logical partitions, so you'll have to put it in a primary partition. However, Linux will happily boot from logical partitions.

Offline

#10 2009-01-19 03:28:43

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Well, right now I have 4 primary for arch, one is mounted at /, one mounted at /home, one is swap and one is boot (where grub is) how can i consolidate these into 3? thanks.

Offline

#11 2009-01-19 03:39:15

viga
Member
Registered: 2007-06-12
Posts: 112

Re: [Solved] Want to resize /home partition, is this possible, how?

Download gparted and make a cd. Use Gparted and delete the partition that you do not want.  Move all your data first to the partition you are going to keep.  You do not need to have a /home.  You could use / for home.   
  you can also create an extended partition

I am sure there are many other people in this forum with better advice.

Offline

#12 2009-01-19 03:39:50

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Well, is there anyway to combine the partitions without losing anything?

Offline

#13 2009-01-19 03:39:57

zyghom
Member
From: Poland/currently Africa
Registered: 2006-05-11
Posts: 432
Website

Re: [Solved] Want to resize /home partition, is this possible, how?

first of all: you don't really need /boot on separated partition
second: if this is your order (/ /home swap /boot) then you should (as I see from your first post you don't have much data on /home) copy all from /home partition to /home2 adn /boot to /boot2
then unmount /home swap and boot
rename /boot2 to /boot, reinstall grub
then use (g)parted to make whatever changes you need: i.e.
/dev/sda1  / (this don't touch as all your files are here now)
/dev/sda2 /home
/dev/sda3 /windows (ntfs)
/dev/sda4 extended
/dev/sda5 swap

format  which needed, mount, move back /home2 to /home
that should be all

that is quiet rough procedure, I might be missing details but the idea as I wrote is working - I have done lots of partition changes without any loose of data


Zygfryd Homonto

Offline

#14 2009-01-19 03:45:22

pointone
Wiki Admin
From: Waterloo, ON
Registered: 2008-02-21
Posts: 379

Re: [Solved] Want to resize /home partition, is this possible, how?

Best bet in my opinion is delete swap (since it is completely unnecessary) and create an extended partition in which you can re-create swap and a new /home partition. Then simply copy all data from the old /home to the new /home and re-format the old /home as NTFS.

I believe this to be the safest route.


M*cr*s*ft: Who needs quality when you have marketing?

Offline

#15 2009-01-19 03:46:33

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

okay, i wrote that poorly, ther oder is /boot, /swap, /, /home (sda1,sda2, etc. respectively)

when i create /home2, what file system do i use? same for boot2

i'm a little confused. i keep /, that's because everything is there. that makes sense. now what will be in the final /dev/sda2 /home...the same stuff that was in my current home, just as a smaller partition? and is this still a primary? then i make the extended, what goes in there?

Offline

#16 2009-01-19 03:48:31

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

okay, i'm currently trying what pointone recommended, thanks.

Offline

#17 2009-01-19 04:00:25

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

OKAY. good!

I now have /hda1 as the boot
/hda2 is extended with both my home and swap
/hda3 is /
and /hda4 is ntfs for winxp

How do i add /hda4 to grub so that I can boot off windows?

Offline

#18 2009-01-19 04:04:42

zyghom
Member
From: Poland/currently Africa
Registered: 2006-05-11
Posts: 432
Website

Re: [Solved] Want to resize /home partition, is this possible, how?

/boot/grub/menu.lst

title Windows
rootnoverify (hd0,3)
makeactive
chainloader +1


Zygfryd Homonto

Offline

#19 2009-01-19 04:18:27

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Okay, i did all the resizing and went back into arch to make sure everything is good. one problem, my swap partition (part of the extended partition) isn't automatically recognized. When I go to gparted inside arch, i rightcliked and hit swapon, and now it's recognized. How can i automate this upon loading?

What line do i add to /etc/fstab

the one i want is /dev/sda5

I got it. yay, i'm getting better smile

Last edited by playdafunkimuzic (2009-01-19 04:24:33)

Offline

#20 2009-01-19 04:27:01

zyghom
Member
From: Poland/currently Africa
Registered: 2006-05-11
Posts: 432
Website

Re: [Solved] Want to resize /home partition, is this possible, how?

swap is switched on in /etc/rc.sysinit:

status "Activating Swap" /sbin/swapon -a

/etc/fstab:

/dev/sda5 swap swap defaults 0 0


Zygfryd Homonto

Offline

#21 2009-01-19 04:59:47

playdafunkimuzic
Member
Registered: 2008-10-25
Posts: 220

Re: [Solved] Want to resize /home partition, is this possible, how?

Uh oh...so, I installed xp on the partition of NTFS and it would automatically boot into xp. I went into gparted, switched boot back to my boot partition. Now i get : Error loading operating system

Offline

#22 2009-01-19 09:56:30

robmaloy
Member
From: Germany
Registered: 2008-05-14
Posts: 263

Re: [Solved] Want to resize /home partition, is this possible, how?

playdafunkimuzic wrote:

Uh oh...so, I installed xp on the partition of NTFS and it would automatically boot into xp. I went into gparted, switched boot back to my boot partition. Now i get : Error loading operating system

you need to reinstall grub since windoze wipes it at install


btw what kind of program is the one you need to boot windows for? won't it work with virtualbox?


☃ Snowman ☃

Offline

Board footer

Powered by FluxBB