Re: Moving Home

From: chris (ithinkiam_at_gmail.com)
Date: 09/06/05


Date: Tue, 06 Sep 2005 17:30:57 -0400

CWO4 Dave Mann wrote:
> On Tue, 06 Sep 2005 12:39:07 +0000, Paul Colquhoun wrote:
>
>
>>On Tue, 06 Sep 2005 06:33:57 -0500, CWO4 Dave Mann
>><misterfixit@loveable.com> wrote: | Will Line 4 in my fstab allow me to
>>have my /home on hdb1? Existing /home | copied using cp -a to /mnt/hdb1
>>??
>>|
>>| # This file is edited by fstab-sync - see 'man fstab-sync' for details
>>| /dev/VolGroup00/LogVol00 / ext3 defaults
>> 1 1 | # I think Line 4 below is the way to make the system find 'home'
>>in its new location on the second drive | # LABEL=/home
>>/mnt/storage/home ext2 defaults 1 1 | LABEL=/boot /boot
>> ext3 defaults 1 2 | none
>>/dev/pts devpts gid=5,mode=620 0 0 | none
>> /dev/shm tmpfs defaults 0 0 | none
>> /proc proc defaults 0 0 | none
>> /sys sysfs defaults 0 0 |
>>/dev/VolGroup00/LogVol01 swap swap defaults
>>0 0 | /dev/sdb1 /mnt/camera auto rw,user,auto 0 0 | /dev/hdb1
>>/mnt/storage ext2 rw,user,auto 0 0 |
>>| TIA!!
>>| Dave
>>
>>
>>Only if you did the extra steps of:
>>
>>1) using fdisk to label the new partition as 'home' 2) removed the
>>'home' label from th eold partition 3) removed the last line from
>>/etc/fstab that mounts /dev/hdb1 as /mnt/storage
>> as you can't mount the same partition twice (well, not that way at
>> least).
>>
>>Personally, I'd just change the 2nd field in th elast line, but I'm
>>old-school unix ;-)
>
>
>
> OK, thanks for the info ..
>
> So, since hdb1 is an entire single HD, may I use:
>
> mklabel label-type
>
> as in " sh ./mklabel /dev/hdb1 home "
>
> But what type to use?
>
> man mklabel says:
>
> Creates a new disklabel (partition table) of label-type. label- type
> should be one of "bsd", "gpt", "loop", "mac", "mips", "msdos",
> "pc98" or "sun".
>
> TIA
>
> Dave
>
I think you missed Paul's point. ;-)
You can quite easily change the line:

/dev/hdb1 /mnt/storage ext2 rw,user,auto 0 0

in your fstab to:

/dev/hdb1 /home ext2 rw,user,auto 0 0

and this will give you your new home where you want it. First, however,
you need to rename your current /home to something like /old_home to
avoid problems. Reboot and it should be sorted.

Chris.



Relevant Pages