Re: repartitioning without losing data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2004-01-01 at 23:02, Jonathan Schwarz wrote:
> I have a need to split my /home partition (which is huge) into two 
> separate partitions, a new home, and a backup partition.
> 
> Is there any way for me to do this without too much hassle/data loss?
> 
> Since I have room on /, is it possible to move home to the / partition, 
> cut that partition, then move /home back? Any ideas or preferred tools 
> for this?

Easy.

1) Reboot to single-user mode.
2) umount /home (if already mounted)
3) mkdir /home
4) mkdir /mnt/home
5) mount -t<type> /dev/<old /home partition> /mnt/home
6) mv /mnt/home/* /home/
7) umount /mnt/home
8) Use parted to repartition and format your partitions (man parted)
9) mount -t<type> /dev/<new /home partition> /mnt/home
10) mv /home /mnt/home/
11) umount /mnt/home
12) rmdir /home
13) Edit /etc/fstab as necessary
14) Reboot

Sounds worse than it is.  It's just a lot of little steps.  I haven't
used parted much, so I'd suggest testing it on another drive first, just
so you get comfortable with it.

P.S.  Sean/Rodolfo/Ed, if I've forgotten anything, please speak up.  I
need sleep.  ;-)

-- 
Jason Dixon, RHCE
DixonGroup Consulting
http://www.dixongroup.net


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux