Welcome to SparkyLinux forums
Zapraszamy również na polsko-języczne Forum https://forum.linuxiarze.pl

Saving and reusing existing home directory

Started by bushyiii, December 31, 2024, 11:33:36 PM

Previous topic - Next topic

bushyiii

I had a different linux OS with my HOME directory on a different partition from the OS.  During the install I chose to overwrite the existing OS's partition for Sparking and used to option to save the existing HOME partition.

I assume that after the install my old exiting home directory would now be my Sparky home directory.  I was wrong.  Is there a way I can still achieve my objective?

bin

What you want to do is absolutely fine. But, there are a couple of things that you have to remember. Your /home contains not only all your files and data but also all the configs and other hidden files that make stuff work.
Some of these can be re-used, some not.
Also, linux doesn't remember you as a name but as a user number. So, if I do "id -u robin" it returns user id 1000. 1000 is used by nearly all linux distros as the starting point for user ids, but not all.
That can mess things up doing what you suggest as all the files will have the wrong permissions.
Depending on how the installer is configured it may be that in your case it sees your current home is fully populated and therefore doesn't do anything else.

I use the method you have described all the time. However, what I do is to boot the live/installer medium, then use that to access my hard drive. I then navigate to my /home and rename my home folder using the move command mv. So it would be as shown in the linked image - that's on pcloud. Move - Rename homeAs you can see I have booted off Sparky KDE and accessed the drive via the file manager.
If I had hit enter then my /home would have been renamed. I would then proceed with the installation using manual partitioning as you do.
I set up the user from scratch using my normal user name and once installation is complete I then move what I want from the robinold folder to my new robin folder.
As always - you should always have a full backup before doing this.

View the most recent posts on the forum