0

I am installing Debian for the first time ever. I picked the "testing" version. I am going through the "expert" GUI installer. I got to the part where it asks how you want to partition your harddrive.

If I install Debian with one big partition for all files (/,/var,/tmp,/home,swap), in the future will I be able to upgrade to the next version of Debian without losing my files under /home?

Or do I need to install on separate partitions to save my /home files when I upgrade in the future?

3

Set it up so that the /home directory is on a separate partition. That way, if you have to do a fresh install, you can reformat the other partitions and keep the current /home directory. You can even have your /home directory as a second disk, and put 2 or more versions of Linux separate root partitions! I use a small main disk 80Gb (hda) for a root drive (/, /boot, /usr, /var, /etc, etc) and then a 1Tb (hdb) disk for /home. I've reused the same /home drive for Debian, Ubuntu and LinuxMint since Ubuntu and Mint are derivatives of Debian.

3

You can absolutely keep /home on the same partition. I always do that, and have never had any problems upgrading. Upgrades won't try to repartition anything, they'll just replace files in-place.

Whenever I've tried to split up partitions I've ended up running out of room on one of them and had to work around it or re-install just to fix that problem!

1

Use LVM instead. It's more flexible. For anything but a small installation, you certainly want multiple filesystems.

The reasons include:

  1. If you have a runaway process that is trying to fill up your disk, it will be contained within the filesystem. With a single filesystem it can fill your entire disk.
  2. If you want to do a reinstall, it makes sense to have user data on separate filesystems. That way, the user data filesystems can easily be excluded from the reinstall. This usually includes /home, at least.
  3. Sometimes backups can be more convenient if you have different things on separate filesystems. For example, you may want to "freeze" a filesystem, e.g. with LVM snapshotting or similar. In that case, clearly you can't have everything on a single filesystem.

Specific recommendations:

  1. Have user data on separate partitions.
  2. Have root (the system) on a separate filesystem from everything else, because you can't easily unmount root.
  3. You might want to put database data on its own filesystem, because it can require special handling.
  4. Having virtual machines on separate filesystems is also a good idea, because you may often want to create, resize, or destroy them.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.