2

I'm thinking about upgrading my company's integration server with a the repos on a separate disk that would be shared with a backup server. Like so:

[Main Integration Server] ---R/W--- [Repo Vdisk] ---R/O--- [Backup Integration Server]

My problem is that according to the GCE docs, if I attach the same Vdisk to more than one instance, all instances must only access the disk in read-only mode. What I'm looking to do would be to have one instance access it in read-write, and one in read-only mode.

Is this at all possible without powering up a third instance to act as a sort of "storage server"?

Zalán Meggyesi
  • 624
  • 5
  • 19

1 Answers1

1

As you quoted from the docs and as mentioned in my earlier answer, if you attach a single persistent disk to multiple instances, they must all mount it in read-only mode.

Since you're looking for a fully-managed storage alternative so you don't have to run and manage another VM yourself, consider using Google Cloud Storage and mount your bucket with gcsfuse which will make it look like a regular mounted filesystem.

Community
  • 1
  • 1
Misha Brukman
  • 12,938
  • 4
  • 61
  • 78
  • Thank you for pointing out gcsfuse - I looked into using that myself, but I came to the conclusion that the traffic to our repo would become prohibitively expensive if using GCS, not to mention performance issues when commits are written out. – Zalán Meggyesi Sep 07 '15 at 07:02
  • @ZalánMeggyesi What about using [`sshfs`](http://fuse.sourceforge.net/sshfs.html) with a single VM acting as central data storage node, and others mounting it via FUSE SSH? Or maybe you want to use NFS or SAMBA instead. – Misha Brukman Sep 08 '15 at 21:53