Fedora Linux Support Community & Resources Center
Old 9th July 2007, 07:54 PM
KiwiPete Offline
Registered User
Join Date: Jul 2007
Posts: 1
How to share /home partition with Ubuntu

Hi there from a newbie Fedora user.
I've been dabbling with Linux for 6 months or so, and initially set up a dual boot system with WinXP and Ubuntu (6.10 and recently upgraded to 7.04).
I had heard a lot of good things about Fedora, so thouht I'd add Fedora 7 as a third OS on my machine.
Here is how my two hard drives are partitioned and used:

Drive 1 - 60 Gb - just one partition - NTFS - WinXP and files/docs.

Drive 2 - 300Gb - partitioned as follows:
Partition 1 - 10Gb - NTFS - reserved in case I ever want to add another Win OS - nothing on it at the moment.
Partition 2 - about 263 Gb - ext3 - used for /home by Ubuntu 7.04
Partition 3 - 15Gb - logical partition divided into 3 sub-partitions, 5,6 and 7 see below.
Partition 4 - 2Gb - swap
Partition 5 - 5Gb - ext3 - / for Ubuntu 7.04
Partition 6 - 5Gb - ext 3 - / for Fedora 7
Partition 7 - 5Gb - ext3 - reserved for / for another Linux partition if I ever want it.

Right, here is my question...
I want Fedora and Ubuntu to share the /home partition (partition 2) so that user settings and files are common to both OS.
When I installed Fedora, I specified Partition 2 as /home but afterwards had prblems with files in that partition appraently locked - could read them but not write them - problem with permissions I assume. I was unable to fix that - and there were other problems too.
Someone on the Ubuntu foum suggested that Ubuntu and Fedora would need to share common User abd Group IDs before they coukld share the /home partition. So I used grep <my user name> /etc/passwd in both OS to se the UID and GID and yesd they were different - Ubuntu was 1000:1000 and Fedora 500:500. So I edited the Fedora passwd file to make it 1000:1000. And I then copied the mount details for /home in Ubuntu and appeneded them to /etc/fstab in Fedora. Tis was all on the advice I got in the Ubuntu forum.
This did not help - in fact I am now unable to login to Fedora at all.
After entering my username and password, message said something to the effect of /Home could not be accessed and would be ignored.
It then presented the option to Log Off or Continue.
When I chose Continue, another message displayed saying access was denied.

It looks like I may have to re-install Fedora to fix this.
Can someone advise me on how I can set up a shared /home partition with Fedora and Ubuntu?

Thanks - sorry this post is so long and involved!

Reply With Quote
Old 9th July 2007, 08:19 PM
JN4OldSchool Offline
"Sean The Terrible" -- The forum(er) Vista® rep
Join Date: Nov 2005
Posts: 8,823
you have a basic conflict going here. Can I suggest a different method, but one which may require you to rethink the Ubuntu install also? You dont want to share a common /home, especially between two different distros. Instead, what would be ideal, to save partitions, is to include /home in each / partition on each distro. But dont make it huge, just 15-20GB for each / partition. Then create a shared partition, labled whatever you want. Say /JoeBlow. Then just mount /JoeBlow in each distro and keep all the stuff you would normally keep in /home in here/ Use /home just for .config files for that distro, as a DL repo and a place to extract and build. When you want to upgrade any given distro by clean install just cp what you want to save from that /home to /JoeBlow and move it back when the new distro is installed. You still might also want to use the userID of 1000 when you reinstall Fedora too. In fact, I use the same user name and ID on all my multi-boots. This has saved me a few times as far as permissions go. Hope this all made sense.
Reply With Quote
Old 9th July 2007, 08:37 PM
moljac024 Offline
Registered User
Join Date: Jun 2007
Posts: 52
It's not a good idea to share the same username between different linux distros, the same /home partition is fine, just as long as you have a different username for each distro.
Reply With Quote
Old 9th July 2007, 08:46 PM
JN4OldSchool Offline
"Sean The Terrible" -- The forum(er) Vista® rep
Join Date: Nov 2005
Posts: 8,823
Originally Posted by moljac024
It's not a good idea to share the same username between different linux distros, the same /home partition is fine, just as long as you have a different username for each distro.
Can you please explain your reasoning behind this?
Reply With Quote
Old 9th July 2007, 09:30 PM
JN4OldSchool Offline
"Sean The Terrible" -- The forum(er) Vista® rep
Join Date: Nov 2005
Posts: 8,823

OK then, let me further explain my reasoning. First off, if you are multi-booting these different distros on the SAME computer, how many are going to be up and running at the same time? And anything you install in any of these distros, where does it go? Let me expound on that, provided you DO NOT share a /home then EVERYTHING belonging to a given distro will remain with that distro. But what if you want to move, say, your installed X-Plane folder between distros. I have mine installed in my shared partition. But guess what? When Fedora 6 was ID 500 and Debian etch was ID 1000 I couldnt play in debian! Even though it was in a shared partition with full read/write permission debian would not run the game. I tried everything to make this work. And I have ran into this same scenerio with a few other apps/files such as VMWare installed distros. So when I installed F7 (clean install) I gave it ID1000 and the same user name (which it had anyway) and simply "reclaimed" the needed files in my shared partition and presto, works great now. Both distros now think it owns these folders.

Now, as far as sharing a /home, what I mentioned above is a reason not to do this. I have successfully shared a common /home between multiple distros, but you run into serious problems when you do have two UID500 users running KDE and they want different wallpaper. I have encountered ALL KINDS of stupid conflicts between .config files. There is just no point in this other than being able to retain your settings when you upgrade with a fresh install. However, even doing this can cause problems, especially between versions of Firefox. It is much easier to keep wallpapers, graphics, beryl screens, and such in the shared partition and when you upgrade just cp the things you want to retain like the .mozilla file.

This is my reasoning and if anyone has any valid reasons why any of this might be a mistake I would love to hear them. I am always learning too.
Reply With Quote
Old 9th July 2007, 10:49 PM
bodhi.zazen Offline
Registered User
Join Date: Jul 2006
Location: Montana
Posts: 732
JN4OldSchool : I do as you say. Each distro has a /home in / and I have a shared /data partition. I agree that config (. files) in /home can confilict and it is the data you want to share (usually) not the config files (although I maintain a mean .bashrc)

You may have similar problems in /data as in /home (uid=500 in Fedora, but uid=1000 in Debian).

So ...

use group management with /data. Either make all directories/files with group ownership = users or make a new group, say data.

So files are owned by root.data with permissions of 660 (or 770 if needed).

Now anyone in the group data has access to the shared data ... and you can keep the riff-raff out.

If you copy .mozilla to $HOME do not forget to chmod ownership
If it is not broken, tweak it... If you break Fedora you get to keep both pieces :p
Reply With Quote
Old 13th July 2007, 05:22 PM
moljac024 Offline
Registered User
Join Date: Jun 2007
Posts: 52
Sorry, my post was a little short and lacking reasoning.

I too am now using a /data partition after several problems caused with the same /home partition. using the same /home and username with different distros (or even distro reinstalls) is catastrophic...
Reply With Quote

or home, partition, share, ubuntu

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Conflicting permissions when sharing home partition between Fedora 10 and Ubuntu prejudged_fire Alpha, Beta & Snapshots Discussions (Fedora 10 Only) 10 16th November 2008 10:58 PM
share ext3 between ubuntu and fc5 grimmson EOL (End Of Life) Versions 5 17th August 2006 11:08 PM
/home partition vs. /home directory leasure98 Using Fedora 3 28th May 2004 04:39 AM

Current GMT-time: 09:49 (Thursday, 17-08-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat