sharing data between linux distros

I need share some data between linux distros installed on hdd. Does it matter if these will be placed for example in /shareddata or /home/shareddata ?

I guess the most recommended way is to create partition for data only, but reason in this case is utilizing free disk space of existing distros without changing partitions.

I assume this is a multi boot situation. I also speak to you as being the system manager (root).

The most important thing you should understand is the ownership of file by user and group. And the permissions that are related to that.

Thus in your case, it is important that the same users on the different systems should have the same UID and use the same GID. Remark that it is not needed to have the same USERNAME for thoses UID, but having the same name will help in understanding and managing those users (same for groups).

You do not explain who needs those so called “shared” data. When it is user data for user x who can login on both systems, I would probably provide that space (because it is only data space where the user can put files at his liking and then accessing them and that all on both systems, so no “sharing”, just having it available at both systems) on a separate file system and mount that file system for the user on a place he thinks convenient (like /home/x/data-on-both-systems). You (as system manager) then creates /etc/fstab entries on both systems for that. And you check that the user has created those mount points in both his home directories. He then creates, etc. files there, which will by defaulot become his own and thus be accessibel on both systems.

BTW another way to do mounting in such a case is favoured by some. Mounting it low in the tree. e.g. at /mnt/data-of-x. And then user x should create a symbolic link from within his home directory to /mnt/data-of-x/. In that case, root is responsible for creating the mount point /mnt/data-of-x/, thus root must then change ownership of it to x (and to the primary group of x) to allow access.

Does each Linux Distro have it’s own user’s /home/ directory or, do you have a common /home/ partition in a partition separate from the partitions where the Distros have their system directories?

Yes, it’s multi boot, single user situation.

Each Linux Distro have it’s own user’s /home/ directory.

@MakeTopSite:

Then, it should be possible to mount each Distro’s partition under /mnt/ and access the individual /home/ directories that way – in principle it’s no different to mounting NAS boxes by means of NFS …


 > ls /mnt/
Distro-Partition-00001
Distro-Partition-00002
Distro-Partition-00003
 .
 .
 .
Distro-Partition-10000
 >