LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 05-01-2015, 07:49 PM   #1
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Rep: Reputation: Disabled
/home directory moves after installing f21


hi all,
good day :-)

i just installed f21 today (clean install over f19) on my duel boot system. everything is working fine except some small problems, especially with my old /home directory.

while installing, i just put a mount point '/' on my previous / (root) directory and marked it to format. i kept everything unchanged and before the installation began, it showed that only this directory will be formatted and recreated, nothing else.

after installing, i find my new /home directory has empty folders. then i saw two new directories have been created, named '152 gb volume' (that was the size of my previous /home) and '157 mb volume' (from the size, i think its the previous /boot). the 152 gb volume has a folder with my previous (and same with new) username, which contains all the contents of my previous /home.

now, will it be possible to merge this two /home directories? i dont want to manually copy all the contents, as the new /home shows only 2.6 gb free space while my old /home has data more than 140 gb. i really want to have a single /home for all my data.

thanks is advance.
 
Old 05-01-2015, 07:59 PM   #2
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
You just need to mount your old home volume on /home

Clean out (or move) the new contents first.
 
1 members found this post helpful.
Old 05-01-2015, 08:06 PM   #3
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,623

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
mind you that jumping from 19 to 21
almost non of the fedora 19 config files in your OLD home folder will work well in fedora 21


manually bring them over one at a time and manually edit the NEW config files to import the 19 settings
 
Old 05-03-2015, 06:59 AM   #4
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
thanks for ur replies. :-)

now,
Quote:
You just need to mount your old home volume on /home
Clean out (or move) the new contents first.
how can i do that? i'm kinda newbie to linux and don't know much about this stuff. any guideline or tutorial will be appreciated.
another thing, if i mount my old /home over new, will it merge the two of them or will it just show the old contents on the new /home? when i install a newer version of fedora, will a third /home will be created?
as it is fresh install, so the new /home is almost empty, i dont have anything important there at all.
 
Old 05-03-2015, 07:21 AM   #5
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by John VV View Post
mind you that jumping from 19 to 21
almost non of the fedora 19 config files in your OLD home folder will work well in fedora 21


manually bring them over one at a time and manually edit the NEW config files to import the 19 settings
thanks, but i'm not clear about the config files. i don't want the old config files, i want only the personal data like video, music, doc, pics etc. importing the old setting are also not that important, as i haven't changed the setting much.

and manually copying data is not an option for me, pls read the constraints with the space on my first post.
 
Old 05-03-2015, 03:12 PM   #6
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
Your new /home contains the files of the users in your new /etc/passwd

If you used the same username, probably you should rename the user dir in you old home.

I would do something like this:

Boot into single user mode.
Code:
mkdir /mnt/oldhome
mount /dev/oldhomevol /mnt/oldhome
mv /mnt/oldhome/user /mnt/oldhome/user.old
cp -ar /home/* /mnt/oldhome
Verify the copy.
Code:
rm -rf /home/*
edit /edit/fstab to add line to mount homevol on /home
reboot
move your data and any wanted configs from /home/user.old to /home/user

Last edited by descendant_command; 05-03-2015 at 03:13 PM.
 
1 members found this post helpful.
Old 05-03-2015, 07:11 PM   #7
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,120

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
That should work - this time. Not so long ago Fedora changed uid/gid values which makes this fragile.
The long term solution is simple (I use it all the time). When re-installing, make sure your old /home partition is mounted during the partition stage (don't format it). Use same username/password(s). Everything gets managed for you.
Would be a simple/clean solution this time too - just reinstall F21.
 
1 members found this post helpful.
Old 05-03-2015, 07:21 PM   #8
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
hi,
thanks for the details.
i'll try that and update the result here.
 
Old 05-03-2015, 07:38 PM   #9
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
That should work - this time. Not so long ago Fedora changed uid/gid values which makes this fragile.
The long term solution is simple (I use it all the time). When re-installing, make sure your old /home partition is mounted during the partition stage (don't format it). Use same username/password(s). Everything gets managed for you.
Would be a simple/clean solution this time too - just reinstall F21.
that is exactly what i did during the installation (or was it)?
i put a mount point /home on my previous home directory and used the same username and password. it worked for me when i installed f19 previously.

if it works again, i can try to reinstall freshly (formatting only the / (root)), as it a new install and i wont lose much data. would u suggest that?

another thing, here is the output of my df -h:
Quote:
Filesystem Size Used Avail Use Mounted on
/dev/sdb5 7.8G 5.1G 2.3G 70% /
devtmpfs 989M 0 989M 0% /dev
tmpfs 999M 92K 999M 1% /dev/shm
tmpfs 999M 844K 999M 1% /run
tmpfs 999M 0 999M 0% /sys/fs/cgroup
tmpfs 999M 1.1M 998M 1% /tmp
tmpfs 200M 36K 200M 1% /run/user/1000
it does not show my old /home, which is around 152 GB. so i guess this installation has created a new partition for that.
i hope this may help u to understand and suggest me further on this issue.

Last edited by oceanmbs; 05-03-2015 at 07:47 PM. Reason: additional info
 
Old 05-03-2015, 08:44 PM   #10
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,120

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
No, there is no partition for it, merely a directory under the root (/).
You apparently didn't use the old /home when re-installing - so yes, I would just re-install, taking care to mount the old /home at the approriate time.
 
1 members found this post helpful.
Old 05-04-2015, 07:40 AM   #11
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
No, there is no partition for it, merely a directory under the root (/).
You apparently didn't use the old /home when re-installing - so yes, I would just re-install, taking care to mount the old /home at the approriate time.
thanks, i'm doing that.
but before that, i want to make sure the whole process again, so i dont mess it up this time also.


after i select the destination,
for the / (root), i'll put a mount point / over the current one and mark for format.
i'll find the old /home (by the size) and put the mount point /home on it and won't mark for format.

and will leave everything unchanged.
is that correct?
 
Old 05-05-2015, 06:08 PM   #12
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
hi syg00,
can u pls confirm the procedures i mentioned above? i need to be sure, so i don't mess it up.
 
Old 05-05-2015, 08:10 PM   #13
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,120

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Have you read my sigline ?.

That looks ok, but
Quote:
and will leave everything unchanged.
is not correct. The very reason for doing it this way is to ensure all the necessary config files under your home are updated for new versions. Some apps will need to be manually re-installed of course.
If you are worried about your data - as you should be - take a backup before you begin.
 
Old 05-08-2015, 05:46 PM   #14
oceanmbs
Member
 
Registered: Jul 2013
Location: Dhaka, Bangladesh
Distribution: Fedora
Posts: 43

Original Poster
Rep: Reputation: Disabled
thank u all for ur advises. finally i've done it.

to keep all the old files in the same /home, i followed the same steps i mentioned at the last post.

this time, the only thing i changed is, while creating a user (having the same name, username and password), to mention the home directory, i changed /home/home to only /home.

now my old /home is in the new /home. all the data are there under a folder name as the username, where the new /home contains the standard home folders (like download, documents, picture etc), initially empty. but this time, as they are at the same place, (previously were under a different '152 gb filesystem') so i can easily copy the contents of my old folders (download and etc) to the new one.

thanks again to all the helpful members of this community.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help installing a .rpm in home directory protolocke Linux - Software 3 11-16-2010 08:50 AM
Printing a message on the console when the user moves to specific directory mohit052 Linux - Newbie 1 05-13-2009 02:58 AM
installing programs on home directory helltone Red Hat 4 08-02-2008 05:14 AM
contents of 'home' directory found at sda5: mounted as /home, and also on sda6:/home leswatson Linux - Newbie 4 04-18-2008 04:02 PM
Help with installing tcl into home directory tuxfood Debian 3 07-31-2005 06:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 02:33 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration