Cookbook to get home into separate partition !?

Avi Greenbury avismailinglistaccount at googlemail.com
Mon Apr 7 12:52:35 UTC 2008


On Mon, 07 Apr 2008 17:24:04 +0800
SYNass IT Ubuntu / Linux <i-ubux at synass.net> wrote:


> Can you help me with an easy understandable and usable cookbook to get
> it done ???

How I'd do it, as root[1]:
1) Fire up GParted (System -> Administration -> Partition Editor under Ubuntu. QTPartrted is pronbably more suitable for kubuntu, both are in the repositories) and create yourself a /home partition. Note down its /dev/sdxx or /dev/hdxx address and filesystem type (i'd go with ext3).
2) Create a directory under /media to mount it under:
	mkdir /media/home
3) Mount it:
	mount -t ext3 /dev/sdxx	/media/home
4) Move everything accross
	mv /home/* /media/home/
5) Add a line to /etc/fstab to make it mount on boot:
	/dev/sdxx	/home	ext3	defaults	0	1
6) Unmount it from /media/home
	umount /media/home
7) Remount it using /etc/fstab
	mount -a
8) Carry on as if nothing happened.

[1] You don't need to be root for all of this. You wont be able to mount the new partition, and may well not be able to move the files, if anyone other than root is logged in, though. I forget whether Ubuntu lets root login graphically, but everything after point 1) can be done in a text terminal.

-- 
Avi Greenbury <ialoneambest at gmail.com>




More information about the ubuntu-users mailing list