Resize ext3 Partition

Jeff Vian jvian10 at charter.net
Mon Jan 24 05:13:08 UTC 2005


On Sun, 2005-01-23 at 17:10 -0800, Shane Archer wrote:
> At 10:31 PM 1/22/2005, you wrote:
> >1. create the new partition and format
> >2. mount the new filesystem somewhere. (mount /dev/hdXY /mnt)
> >3. copy all the files from old to new
> >    cd /home
> >    cp -a <username> /mnt
> >
> >Now it gets tricky, because once the filesystem is mounted you cannot
> >remove the old files from /home
> >
> >4. logout, and log back in as root (you need to not have any files in
> >the /home being used)
> >5. edit /etc/fstab and create a line to mount the new filesystem at the
> >chosen location
> >(/dev/hdXY   /home    ext3    defaults   1 2) or equivalent.
> >6. delete all the files in the original /home (rm -rf /home/username
> >7. mount the mew /home
> >    mount -a
> >8. verify it mounted properly
> >    mount
> >9. logout and log back in as your regular user and you are done.
> >
> >Note that if you have more than one user in /home, the cp command in
> >step 3 and the rm command in step 6 will be required for each user.
> >
> >Also note that it will be a good idea to use the du command to confirm
> >what size partition is required before you create it.  (du -s /home)
> 
> Hi Jeff,
> 
> Thanks for the assistance. I was able to move things around and re-mount 
> the new /home with no problems. In the end I may back things up and do a 
> fresh install on a new partition on this box, but this was a good learning 
> experience. Thanks again!
> 
> Shane 
> 
Glad to help and nice to know it worked.
I assume it gave you the space you needed for the db you were wanting to
move in.




More information about the fedora-list mailing list