xfs
[Top] [All Lists]

Re: Write event -> dm_read_invis?

To: Dean Roehrich <roehrich@xxxxxxx>
Subject: Re: Write event -> dm_read_invis?
From: Ben Myers <dative@xxxxxxxxxxx>
Date: Thu, 03 Feb 2005 17:50:29 -0600
Cc: linux-xfs@xxxxxxxxxxx
In-reply-to: <20050203202540.A38B94FDCA@xxxxxxxxxxxxxxxxxxxxxxxx>
References: <20050203202540.A38B94FDCA@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: linux-xfs-bounce@xxxxxxxxxxx
On Thu, 2005-02-03 at 14:25 -0600, Dean Roehrich wrote:
> The dm_read_invis will see what was written by the write(2), provided the
> write has occured.  The write(2) won't actually happen until sometime after
> your call to dm_respond_event.
> 
> Your data migration app cannot know when the write(2) (that goes with the
> DM_EVENT_WRITE) is finished.  There's nothing in the DMAPI spec, anyway, that
> would provide for this--there's no such thing as DM_EVENT_POSTWRITE.

Pity. DM_EVENT_POSTWRITE is exactly what I'm looking for.  How about
dm_sync_by_handle()?  If I respond with DM_RESP_CONTINUE and then
immediately sync that file, won't I block until the write is finished?

> If mirroring or snapshotting is what you want, then maybe a volume manager
> would be a better solution?

I'm hoping for something more along the lines of logging.

Anyway.  Thanks,
Ben

-- 
Ben Myers <dative@xxxxxxxxxxx>


<Prev in Thread] Current Thread [Next in Thread>