1

I'm going to make a dual (or more) boot setup to allow an extended look at two or more flavors of Ubuntu. I typically set /home in its own partition. It would be convenient to have the same partition as /home for all installations. I'll be using a single drive. How practical is this?

I can foresee difficulty if the same programs are installed in separate instances. Is there a practical way to link most storage space in /home across all instances but keep settings separate?

  • No, not practical precisely because there's no way to keep separated settings. – ChanganAuto Mar 08 '22 at 19:15
  • Ok, what I want is to use one partition as storage for all /home instances. I think I could do this by mounting different directories (Documents, Pictures, Downloads, whatever) from their location in the original /home to their corresponding locations in each extra Ubuntu-flavor installation - thus keeping only one copy of whatever I create or save there no matter which OS I've booted. I'd use fstab in each bootable partition to do this. Is this plan flawed? – Twelve Kanaw Mar 08 '22 at 20:11
  • Different distributions will have different software and different versions of software. All of them will store configs in home in a different way which often leads to conflicts. It's not very practical to use a single /home for more than one installation. If you want a shared partition, it makes more sense to just create a partition for that purpose and store your files there instead of /home. Keep your /home on the root file system for each installation. Nothing is forcing you to keep your Documents in ~/Documents and your pictures in ~/Pictures, etc – Nmath Mar 08 '22 at 20:21
  • Furthermore if you just want to try a different DE, why go thru the hassle of installing it? You can try any Ubuntu flavor in a live session by choosing "Try Ubuntu" when booting from installation media. This won't affect your installed system and makes it a lot easier to try different flavours and distros. – Nmath Mar 08 '22 at 20:25
  • I have a single /home partition for my Kubuntu and Mint OS's, but I won't recommend it. It leads to trouble as you use both systems. Ran into troubles with this. As @Nmath suggested it would be better to just share your Documents, Downloads, Music etc. You could make a seperate partition for that. – Joepie Es Mar 08 '22 at 20:37
  • I have many installs, and keep /home inside / (root). But then /home is small as I have all data including some hidden folders like Firefox & Thunderbird in my data partition. (not sure about Firefox as snap as I do not use snaps). https://askubuntu.com/questions/1013677/storing-data-on-second-hdd-mounting & https://askubuntu.com/questions/1058756/installing-all-applications-on-a-ssd-disk-and-putting-all-files-on-hdd-disk – oldfred Mar 09 '22 at 03:33

1 Answers1

0

Indeed do not just use one common /home for different linux distributions. This is not guaranteed to work, even more if the linux distributions are quite different.

Instead share your user data only between the installations.

  • Set up each distribution with a separate /home
  • Make sure each user on each distribution has the same UID and the same user name. Having the same UID is important, because the permission system identifies users by UID, not by login name.
  • Make all of these distributions access the same user data by replacing the default user folders ("Documents", "Pictures", ...) by symbolic links pointing to the partition where your user data are stored.

Note: Symbolic links work seamlessly from an end user perspective, but you could also "mount bind" instead, which is a bit more complex to set up, but has the "linked" folder behave in all respects like a regular folder.

vanadium
  • 88,010
  • I like the rbind option but I'd consider symlinks as well. I reckon binding several folders will accomplish 90% of what I was after with no complications and maybe more. I'd use the same name and UID across all systems, but for convenience. I hadn't considered UID and permissions. Thanks. – Twelve Kanaw Mar 09 '22 at 11:05
  • Personally, I would use just symlinks. For user navigation, saving files, etc., it works the same as a real directory. Nothing beats the flexibility of symlinks and setting up is as simple as it gets. – vanadium Mar 09 '22 at 14:36
  • I'll try symlinks since it's a method I've rarely used. I'm more familiar with a bind mount in fstab for other uses. – Twelve Kanaw Mar 09 '22 at 20:41