Re: [gentoo-user] Sharing /home and swap

2011-12-28 Thread Neil Bothwick
On Wed, 28 Dec 2011 13:26:41 +0800, Andrew Lowe wrote:

   Thanks for the replies, I forgot about the config stuff sitting
 there in the home dir. I think the way around this for me is Pandu's 
 suggestion of a different user name for each linux and using bind mount.

I normally use the same username but a different home directory, so my
Gentoo home directory is /home/nelz and my SUSE one would be 
/home/nelz-suse. That way you can keep the same username, and UID, in
both distros and not run into permission problems. Sharing directories
can then be done simply with symlinks.

However, for one app, a VM would probably be a better solution. Not only
would it save all this hassle, it would also save having to reboot every
time you wanted to run the program.


-- 
Neil Bothwick

One difference between a man and a machine is that a machine is quiet
when well oiled.


signature.asc
Description: PGP signature


Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Adam Carter
. Is there anything in my
 current Gentoo /home and swap that locks them to the Gentoo install or can
 I share them between the two installs?

No. As long as SUSE supports the file system on /home you're using in
Gentoo it will work fine, and that's very likely. When you're booted
into SUSE, run cat /proc/filesystems to see what it supports. If your
Gentoo /home file system is not there, you may need to load the
module, eg. on this system;
# grep ext /proc/filesystems
ext2
ext4
# modprobe ext3
# grep ext /proc/filesystems
ext2
ext4
ext3



Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Andrew Lowe

On 28/12/2011 10:28 AM, Adam Carter wrote:

. Is there anything in my
current Gentoo /home and swap that locks them to the Gentoo install or can
I share them between the two installs?


No. As long as SUSE supports the file system on /home you're using in
Gentoo it will work fine, and that's very likely. When you're booted
into SUSE, run cat /proc/filesystems to see what it supports. If your
Gentoo /home file system is not there, you may need to load the
module, eg. on this system;
# grep ext /proc/filesystems
ext2
ext4
# modprobe ext3
# grep ext /proc/filesystems
ext2
ext4
ext3




Good, thanks for that.

Andrew



Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Nilesh Govindarajan
On Dec 28, 2011 7:52 AM, Andrew Lowe a...@wht.com.au wrote:

 Hi all,
I usually use Gentoo as my normal Linux but a third party app
I'm about to start using only runs on SUSE. To this end, I'm about to set
aside a smaller partition and install the minimal amnount of SUSE I need to
run the app. My question is regarding /home and swap. Is there anything in
my current Gentoo /home and swap that locks them to the Gentoo install or
can I share them between the two installs? What I mean by share is that
when I boot up Gentoo can I mount /home and swap and everything is fully
accessible and then reboot into SUSE and once again mount them and
everything is once again fully accessible?

I'm not doing anything snazzy such as LVM or encryption, just
bog standard Linux. Any thoughts greatly appreciated.

Regards,
Andrew

Another important factor is desktop environment. Various settings can cause
troubles in either ones.


Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Peter Humphrey
On Wednesday 28 December 2011 02:21:25 Andrew Lowe wrote:

 Is there anything in my current Gentoo /home and swap that locks them to
 the Gentoo install or can I share them between the two installs?

Beware! Whichever your preferred desktop (kde, gnome, whatever), having your 
whole home directory shared between distros is a recipe for disaster. You 
only need one program to differ in version number between distros to render 
the whole lot unusable. Consider, for instance, the current difficulty of 
incompatible versions of kmail between 4.4 and 4.7.

My preference is to have a /home/user/common partition mounted in each 
distro, containing everything I want accessible at all times, but leave 
things like .kde4 dedicated to the distro that's running it.

-- 
Rgds
Peter   Linux Counter 5290, 1994-04-23


Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Pandu Poluan
On Dec 28, 2011 9:40 AM, Nilesh Govindarajan cont...@nileshgr.com wrote:


 On Dec 28, 2011 7:52 AM, Andrew Lowe a...@wht.com.au wrote:
 
  Hi all,
 I usually use Gentoo as my normal Linux but a third party app
I'm about to start using only runs on SUSE. To this end, I'm about to set
aside a smaller partition and install the minimal amnount of SUSE I need to
run the app. My question is regarding /home and swap. Is there anything in
my current Gentoo /home and swap that locks them to the Gentoo install or
can I share them between the two installs? What I mean by share is that
when I boot up Gentoo can I mount /home and swap and everything is fully
accessible and then reboot into SUSE and once again mount them and
everything is once again fully accessible?
 
 I'm not doing anything snazzy such as LVM or encryption, just
bog standard Linux. Any thoughts greatly appreciated.
 
 Regards,
 Andrew
 
 Another important factor is desktop environment. Various settings can
cause troubles in either ones.

True.

My suggestion would be to not share your ~ directly, but instead share
something *under* ~

E.g. :

mkdir ~/sharedstuff
mount /dev/sdxx ~/sharedstuff

Another alternative would be to ensure that you are not using the same
username in both OS, and just do a bindmount.

Rgds,


Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Andrew Lowe

On 28/12/2011 10:49 AM, Pandu Poluan wrote:


On Dec 28, 2011 9:40 AM, Nilesh Govindarajan cont...@nileshgr.com
mailto:cont...@nileshgr.com wrote:
 
 
  On Dec 28, 2011 7:52 AM, Andrew Lowe a...@wht.com.au
mailto:a...@wht.com.au wrote:
  

[snip]
...
...
...
[snip]


True.

My suggestion would be to not share your ~ directly, but instead share
something *under* ~

E.g. :

mkdir ~/sharedstuff
mount /dev/sdxx ~/sharedstuff

Another alternative would be to ensure that you are not using the same
username in both OS, and just do a bindmount.

Rgds,




People,
	Thanks for the replies, I forgot about the config stuff sitting there 
in the home dir. I think the way around this for me is Pandu's 
suggestion of a different user name for each linux and using bind mount.


Thanks for the info,
Andrew






Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread W.Kenworthy
If its only one app, why not use a small vm (qemu, vbox etc.)? - best of
both worlds.

Also, why only on Suse? - you can often work around differences with
ld-preload and other tricks.


BillK



-Original Message-
From: Andrew Lowe a...@wht.com.au
Reply-to: gentoo-user@lists.gentoo.org
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Sharing /home and swap
Date: Wed, 28 Dec 2011 10:21:25 +0800

Hi all,
I usually use Gentoo as my normal Linux but a third party app I'm 
about to start using only runs on SUSE. To this end, I'm about to set 
aside a smaller partition and install the minimal amnount of SUSE I need 
to run the app. My question is regarding /home and swap. Is there 
anything in my current Gentoo /home and swap that locks them to the 
Gentoo install or can I share them between the two installs? What I mean 
by share is that when I boot up Gentoo can I mount /home and swap and 
everything is fully accessible and then reboot into SUSE and once again 
mount them and everything is once again fully accessible?

I'm not doing anything snazzy such as LVM or encryption, just bog 
standard Linux. Any thoughts greatly appreciated.

Regards,
Andrew





Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Andrew Lowe

On 28/12/2011 1:30 PM, W.Kenworthy wrote:

If its only one app, why not use a small vm (qemu, vbox etc.)? - best of
both worlds.


Basically because I've done nothing with these thingies and have no 
experience with them and therefore didn't think of them.. Might be 
worth looking into - got a link to a 20 words or less intro?




Also, why only on Suse? - you can often work around differences with
ld-preload and other tricks.


The third party app is under development, I'm tying some stuff into it, 
and things are a bit fluid at the moment. I think basically taking a 
couple of hours to set something up once and that's it is quicker than 
trying to work around library problems that will arise in an ongoing manner.





BillK




Andrew



Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread Michael Mol
On Wed, Dec 28, 2011 at 12:26 AM, Andrew Lowe a...@wht.com.au wrote:
 On 28/12/2011 10:49 AM, Pandu Poluan wrote:


 On Dec 28, 2011 9:40 AM, Nilesh Govindarajan cont...@nileshgr.com
 mailto:cont...@nileshgr.com wrote:
  
  
   On Dec 28, 2011 7:52 AM, Andrew Lowe a...@wht.com.au
 mailto:a...@wht.com.au wrote:
   

 [snip]
 ...
 ...
 ...
 [snip]


 True.

 My suggestion would be to not share your ~ directly, but instead share
 something *under* ~

 E.g. :

 mkdir ~/sharedstuff
 mount /dev/sdxx ~/sharedstuff

 Another alternative would be to ensure that you are not using the same
 username in both OS, and just do a bindmount.

 Rgds,



 People,
        Thanks for the replies, I forgot about the config stuff sitting there
 in the home dir. I think the way around this for me is Pandu's suggestion of
 a different user name for each linux and using bind mount.

There's a big one nobody mentioned: Different versions of different
apps. In flipping a /home back and forth between different Linux
distributions running different versions of (mostly) the same
software, I've had apps crash. *Usually*, this happens when dotfiles
were created by newer versions of a program, and then read by an older
version, but I've seen it break going the other way, too.

The other (relatively mild) bit are UID/GID mappings for permissions.
As long as your login users and related groups in /etc/passwd and
/etc/group have the same UIDs and GIDs in both OSs, you should be just
fine. I got bit when I flipped back and forth between Fedora and
Ubuntu; Fedora started things at UID 500, Ubuntu started things at UID
1000. Files that had been created by my user account on one system
couldn't be read by my user account on the other without chowning
them.

-- 
:wq



Re: [gentoo-user] Sharing /home and swap

2011-12-27 Thread W.Kenworthy
bunyip ~ # esearch VirtualBox
[ Results for search key : VirtualBox ]
[ Applications found : 8 ]

*  app-emulation/virtualbox
  Latest version available: 4.0.12
  Latest version installed: [ Not Installed ]
  Size of downloaded files: 67,936 kB
  Homepage:http://www.virtualbox.org/
  Description: Family of powerful x86 virtualization products for
enterprise as well as home use
  License: GPL-2

...


I'd recommend vbox then ... just works.  Almost as easy as dual boot and
less risk to the base system (i.e., getting the disk order wrong on
install and overwriting the existing OS) - by the way sharing your home
directory (vs /home as a different user) is fraught - many apps use
different configs depending on versions - 'evolution' for instance could
really break your email as later versions switch to a database format
and subsequent versions fiddle with it.

Install it, open vbox-manager from the menu and create a new VM with
whatever specs you want, put the CD for suse in and point the Vbox CD to
it in setup and go.  You might need to read up on kernel options for
virtualisation if you have a customised kernel vs genkernel to get the
best (almost native) performance.

Love vms for dev work - snapshot it regularly so you can wind back the
clock when necessary ...

BillK

 

-Original Message-
From: Andrew Lowe a...@wht.com.au
Reply-to: gentoo-user@lists.gentoo.org
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Sharing /home and swap
Date: Wed, 28 Dec 2011 13:37:34 +0800

On 28/12/2011 1:30 PM, W.Kenworthy wrote:
 If its only one app, why not use a small vm (qemu, vbox etc.)? - best of
 both worlds.

Basically because I've done nothing with these thingies and have no 
experience with them and therefore didn't think of them.. Might be 
worth looking into - got a link to a 20 words or less intro?


 Also, why only on Suse? - you can often work around differences with
 ld-preload and other tricks.

The third party app is under development, I'm tying some stuff into it, 
and things are a bit fluid at the moment. I think basically taking a 
couple of hours to set something up once and that's it is quicker than 
trying to work around library problems that will arise in an ongoing manner.



 BillK



Andrew