public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* disabling cache to be able to create a http://en.wikipedia.org/wiki/Peer_to_Peer_Remote_Copy solution
@ 2010-04-25 19:16 Folkert van Heusden
  0 siblings, 0 replies; only message in thread
From: Folkert van Heusden @ 2010-04-25 19:16 UTC (permalink / raw)
  To: linux-kernel

Hi,

I'm trying to achive the following

   storage a                   storage b
      |   |                     | |
      |   +--+                  | |
      | +----|------------------+ |    <- fibre
      | |    |                    |
      | |    +------------------+ |
      | |                       | |
    linux a                    linux b
      |                           |
      +-------------+  +----------+    <- iscsi
                    |  |
                   vmware

A trained eye will recognize this as a 'peer to peer remote
copy'-implementation.

So linux a (or b) receive storage requests from vmware and store those
mirrored on storage a and b: both have an md1 on their paths to storage
a and b.

Now let's say vmware talks active/passive to those linux boxes. At some
moment the left path is selected and vmware sends a block to linux a to
store on disk. Linux a stores this block on both storage systems and
_caches this block in memory_.
Then at some time, vmware switches to the path via system b and also
stores at the same block some data.
Then, vmware switches back to path a and reads again this block from
disk. Now here's where the problem comes up: linux a thinks it still has
this block in the memory-cache and serves it from there while in fact,
when the path went through system b, this block was already changed on
the storage!
So to be able to construct this mechanism, I somehow need to be able to
disable the read-cache of linux a and b. I found that you can clear the
cache by entering "echo 3 > /proc/sys/vm/drop_caches" but this can't be
automatically invoked by the vmware system when it switches paths.

Anyone got a suggestion?


Folkert van Heusden

-- 
----------------------------------------------------------------------
Phone: +31-6-41278122, PGP-key: 1F28D8AE, www.vanheusden.com

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-04-25 19:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-25 19:16 disabling cache to be able to create a http://en.wikipedia.org/wiki/Peer_to_Peer_Remote_Copy solution Folkert van Heusden

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox