2

The situation:

I have these virtual machines that are used for building software, and I'm trying to keep all the builds on the same "disk", if you will. The virtual machines:

2 x Windows
4 x Linux (3 Mandriva and 1 CentOS)

What is the best way to share a drive between virtual machines? I am currently using NFS (sharing a drive from Linux -> Windows using Services for Unix), but I'm not sure that is the most efficient.

Sagar
  • 534
  • 3
  • 7
  • 21

2 Answers2

2

I usually lean towards running Samba on Linux to facilitate file sharing with Windows. Mostly because you don't have to worry about setting up custom services on the Windows side. That's a plus for me because I find it easier to implement services on the Linux side.

You can mount the shares using the cifs filesystem type (which supersedes smbfs) on the other Linux machines.

The samba software suite, as well as the cifs kernel module, are usually included by default in most distributions.

chuckx
  • 1,150
  • 6
  • 8
0

which virtual machine are you using ? Propably you could create a common shared disk. Have a look at http://www.symantec.com/connect/articles/building-vmware-shared-disk

Nikolaidis Fotis
  • 2,032
  • 11
  • 13
  • I'm using VMWare. – Sagar Aug 10 '10 at 18:06
  • They use machines with the same OS. I wonder if that would work between Linux and Windows. – Sagar Aug 10 '10 at 18:15
  • Yes, that's the gotcha. With your heterogeneous environment, you would need to find a clustered file system which supports both Windows and Linux. I'm not aware of any non-commercial solution (i.e. costs a lot) which would fit that requirement. – chuckx Aug 10 '10 at 18:31
  • Client or server support? Gluster has native samba support, as I recall. Linux or similar servers. – Ronald Pottol Aug 10 '10 at 20:14
  • If i understood well , The article suggest to "exploit" the fact that they are instances of the same virtual machine and not totally seperate machines. An example of what i mean ... InstanceA -(write)> VMmanager (disk) -(read)> InstanceB So, instead of using some network interface, it's using the fact that they can be connected "internally" via the manager. – Nikolaidis Fotis Aug 10 '10 at 20:30
  • @Ronald: either can be the "server"; technically neither is the server. The problem with nfs is that sharing from windows to linux means I cannot use windows services to access it. I have a work around, but that is not my primary choice. – Sagar Aug 11 '10 at 14:05
  • I might try Samba support. I've never used Samba; can it be used as just another folder? I mean, like you would use nfs mounts? – Sagar Aug 11 '10 at 14:07
  • yes, it can be done. but you lose on performance. – Nikolaidis Fotis Aug 11 '10 at 14:16