Installing debian on existing ubuntu - will /home folder be removed?
Solution 1
I believe that Debian will (or may?) overwrite and effectively remove your home folder and encrypting it is not protection against it getting overwritten.
You should copy your home folder to an external hard drive if possible so you can restore it later.
Backup. Backup. Backup.
Solution 2
First, make sure you have backups. Accidents can happen.
The Debian installer will overwrite the partition that you select to install the system. Shrink the existing partition to make room for a new partition where you'll install Debian. In general, it's a good idea to have a partition for the system and a partition for your data.
Have you made your backup yet?
Boot from a Linux live CD or live USB, such as the Ubuntu live CD or the GParted live CD. Remove all the files outside /home
, then move the directories in /home
one level up, and remove the (now empty) /home
directory. (Of course, if there are files you want to keep outside /home
, make sure not to remove them, just move them to a good place!) Then use the disk/partition manager (I forget exactly what it's called), and shrink the existing Linux partition.
When you install Debian, tell it to use the free space as a partition to install the system. And tell it to mount your existing partition at /home
, without formatting it.
Did you test that your backup was readable and contained all the files it should?
Related videos on Youtube
Gilles 'SO- stop being evil'
Updated on September 18, 2022Comments
-
Gilles 'SO- stop being evil' over 1 year
I want to install Debian with LXDE on partition, that already have Ubuntu 11.04 installed. I have a lot of music there, and I don't want copy it to another partition. I know that Debian installer will propt that on this partition is already linux installed, but will it remove all from my /home/ folder if I type the same username in setup? Or should I have to encrypt this folder?
-
drjors almost 13 yearsIt will likely purge everything on the ubuntu partition prior to installation. You should create a dedicated partition for your music and move your music to there, in my opinion.
-
-
Admin almost 13 yearsOh, thanks, I will backup all tomorrow :)
-
jrg almost 13 years+1 for mentioning "Backup. Backup. Backup." - people don't do it enough.
-
Thorbjørn Ravn Andersen almost 13 yearsReinstalling operating systems on a drive is perhaps the singlemost high dataloss risk operation you can find as it may choose to reformat any drive. Anything you want to survive this should be carefully backed up.
-
Shadur almost 13 yearsIf you keep
/home
on a separate partition and explicitly tell debian NOT to format that partition but instead use it as is, you should be fine.