0

Multiple Linux distros can be installed on the same machine. The format of executables should be the same for every one of them. So I want to use multiple distros on a single machine and have access to some applications like Skype, Chrome or Spotify from all. I don't want to waste time and disk space to install them on distros separately. I want to use only modern distros, like Ubuntu, Mint, Fedora, Solus, Manjaro, etc.

man hier expresses /usr/local as a folder is where programs which are local to the site typically go. I can make a separate partition with the contents of /usr/local and mount it on every distro. Please tell me if this is the appropriate folder.

After mounting the appropriate folder:

  • what is required for executables to be shared among distros (permissions, UID, GID)?
  • will it be possible to install a piece of software on one distro and run it on another?
  • will upgrade of a package on one distro be visible on the other distros?
  • will removal of the package be visible on other distros?
  • should I mount more folders, like /home, /usr/share/games, /usr/share/locale, /usr/bin, /lib, /opt or /var?
  • how about flatpak and Appimages?
1

No, only /usr/local and possibly /opt are safe to share.

not /home because dotfiles may not be compatible across distros. (but you could mount /home elsewhere to make the files available)

not /usr/share becuase the files there are architecture agnositic, but not version agnostic.

all other directories are also under the management of your distro, so sharing them will cause collisions.

  • FWIW, /home is usually safe to share. Very rarely do config files have sufficiently different formats between distros that it's an issue. THe only caveat is that config on one distro will propagate to all of them. – Austin Hemmelgarn May 8 '18 at 19:39
  • i've see it with things like firefox, I'd share the user subdirectories off home, but not the dotfiles – Jasen May 8 '18 at 22:00
  • OK, never tried it with Firefox. In theory, you might be fine if you use different firefox profiles for each distro though, as that would separate out all the stuff that's likely to conflict. – Austin Hemmelgarn May 9 '18 at 18:40
1

As far as I can understand you want to have a multi-boot system where you can boot a different Linux distros at a time, but keeping the same binaries in a shared partition.

What you want to do isn't feasible, and if you were trying to do it, you would be spending 10x more time compared to managing each distro separately. You're opening a gigantic can of worms here.

will it be possible to install a piece of software on one distro and run it on another?

In general, no. Linux executables are compiled differently for each distro. They depend on specific versions of specific installed libraries. You might be able to run on all distros a generic software binary that is not distro-specific, but even a program that doesn't use external libraries and relies on the kernel only would depend on the kernel version, which is very different from distro to distro (e.g. Fedora uses a kernel version which is much more advanced than RHEL's or Ubuntu). Not to mention that the same kernel version might be build with different config options depending on the distro.

what is required for executables to be shared among distros (permissions, UID, GID)?

This is too broad a question. The same package in two different distros might e.g need to run under different users. So, requirements are different depending on the software and on the distro.

will upgrade of a package on one distro be visible on the other distros?
will removal of the package be visible on other distros?

No, each distro has its own Package Manager and package format, and are not compatible with each other (see also this question: Why isn't there a truly unified package manager for Linux?). Trying to mix them up will make a mess. And compiling each software from source to avoid dealing with Package Managers means opening another can of worms.

Concerning your questions about mountpoints and sharing partitions, note that's tricky enough just sharing the /home partition between different distros, as seen in this question: Different linux distros sharing the same /home folder?

0

AppImages are safe to share between different distributions since they do not change the files in the system. In fact, this is one of the main points of the AppImage format - you download an application once, and then can run it on any of your distributions without having to re-download the same application.

You can store AppImages on any partition you want, including network shares.

-1

I think of some possibilities:

• A portable linux executable on a shared folder, with execute permissions: I suppose it should work for command line binaries & shell scripts. But mind that not all applications are provided in portable tar.gz or tar.bz2 formats.

• A cross platform package manager such as Snap or Zero Install with appropriate configurations.

• May be so-called portable applications.

I don't think it is all hard to tweak. But you have to study about package management at your best..

  • 1
    First, you assume that all users use the same architecture. This is far from true. Second, most applications assume a given environment (other programs available, a particular graphics environment, a desktop environment, particular versions of specific shared libraries, even location and naming of configuration files, and so on). All that can't just be brushed aside as you do. – vonbrand May 8 '18 at 14:24
  • Nope... Architecture on same machine - how can it be different?.. I think portable applications are a possibility. As long as a user has admin privileges, it shall be possible to use shared storage locations... – user9600383 May 8 '18 at 15:27
  • In 3rd point, I did not mean binaries portable across Linux platforms but so called portable applications which you can use just by plugging in a USB. I am not a Linux expert but if it is really an issue among techies, it should be possible to build a solution out. – user9600383 May 8 '18 at 15:33

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.