I lost My "/home"

jim barnes mail.list.mail at gmail.com
Sat Sep 22 22:25:11 UTC 2007


On Saturday 22 September 2007 14:30:49 email.listen at googlemail.com wrote:
> Hi Jim
>
> Am Sa, 22. September 2007 17:58:24 schrieb jim barnes:
> > On Saturday 22 September 2007 07:57:54 Suhendri wrote:
> > > Hi All..
> > >
> > > My Desktop was ubuntu-edgy installed. I've splitted my harddisk to 3
> > > partitions, as /, /home and swap file.
> >
> > <snip>
> >
> > > Please help me how to solve my problem.... So i can get all of our
> > > files on /home folder..
> >
> > I gather you repartitioned after installing to separate /home to its own
> > partition? If so, I would proceed cautiously something like this:
> >
> > mount                         # to list present mount points
> > sudo umount /home  # now you have access to your /home files, check!
> > sudo mkdir /newhome        # because you can only have one /home at a
> > time sudo mount /dev/xxxx /newhome  # using info from the mount command
> > above sudo cp -a /home/* /newhome      # make sure directories match
> > after copy!
>
> Shouldn't it be mv and not cp?

I've gotten in the habit of copying, something gets borked along the way and 
you've still got your source files.

> Or a:
>  rm -r /home/*
> is missing here, isn't it?
>
> > sudo umount /newhome
> > sudo mount /dev/xxxx /home        # now /home is where is you want it
>
> You copied the files from /home/ to /newhome but you dindn't delete the old
> files in /home/!
>

As I understand, the old/home is now free disk space if needed, and will be 
overwritten in time.

I welcome any corrections if my logic needs adjusting!

> > Log in, make sure it is as expected.
> > Reboot, make sure it is as expected.
> >
> > sudo rm -r /newhome      # not needed anymore

-- 
Jim Barnes
--
Certainly the game is rigged. Don't let that stop you; 
if you don't bet, you can't win.            -Lazarus Long 
--
Linux 2.6.20-16-generic




More information about the ubuntu-users mailing list