All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tim Post <echo@echoreply.us>
To: jd@commandprompt.com,
	LVM general discussion and development <linux-lvm@redhat.com>
Subject: Re: [linux-lvm] fsync() and LVM
Date: Thu, 19 Mar 2009 17:20:58 +0800	[thread overview]
Message-ID: <1237454458.19345.157.camel@localhost.localdomain> (raw)
In-Reply-To: <1237304003.8159.3.camel@jd-laptop.pragmaticzealot.org>

On Tue, 2009-03-17 at 08:33 -0700, Joshua D. Drake wrote:
> On Mon, 2009-03-16 at 15:51 -0700, Joshua D. Drake wrote:
> > On Mon, 2009-03-16 at 16:53 -0500, Les Mikesell wrote:
> > 
> > > The point of fsync() is for an application to know that a write has been 
> > > safely committed, as for example sendmail would do before acknowledging 
> > > to the sender that a message has been accepted.  The question isn't 
> > > whether an application can call fsync() but rather whether it's return 
> > > status is lying, making the underlying storage unsuitable for anything 
> > > that needs reliability.
> > 
> > Right and for databases this is critical. So enlightenment here would be
> > good.
> 
> Anyone?
> 
> Joshua D. Drake

If a logical volume spans physical devices where write caching is
enabled, the results of fsync() can not be trusted. This is an issue
with device mapper, lvm is one of a few possible customers of DM.

Now it gets interesting:

Enter virtualization. When you have something like this:

fsync -> guest block device -> block tap driver -> CLVM -> iscsi ->
storage -> physical disk.

Even if device mapper passed along the write barrier, would it be
reliable? Is every part of that chain going to pass the same along, and
how many opportunities for re-ordering are presented in the above?

So, even if its fixed in DM, can fsync() still be trusted? I think, at
the least, more testing should be done with various configurations even
after a suitable patch to DM is merged. What about PGSQL users using
some kind of elastic hosting?

Given the craze in 'cloud' technology, its an important question to ask
(and research). 


Cheers,
--Tim

  reply	other threads:[~2009-03-19  9:21 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-13 17:46 [linux-lvm] fsync() and LVM Marco Colombo
2009-03-13 20:08 ` Stuart D. Gathman
2009-03-13 20:29   ` Ben Chobot
2009-03-13 20:38   ` Alasdair G Kergon
2009-03-14  3:16     ` Marco Colombo
2009-03-14  9:07     ` Dietmar Maurer
2009-03-14 14:31       ` Stuart D. Gathman
2009-03-15  0:51         ` Marco Colombo
2009-03-16 11:02           ` Charles Marcus
2009-03-16 11:05             ` Martin Schröder
2009-03-16 11:18               ` Charles Marcus
2009-03-16 11:25                 ` Dietmar Maurer
2009-03-16 14:36             ` Marco Colombo
2009-03-16 17:13               ` Stuart D. Gathman
2009-03-16 17:17           ` Stuart D. Gathman
2009-03-16 18:50             ` Les Mikesell
2009-03-16 19:36               ` Greg Freemyer
2009-03-16 19:55                 ` [linux-lvm] liblvm status question ben scott
2009-03-16 20:58                   ` Greg Freemyer
2009-03-17 10:38                     ` Bryn M. Reeves
2009-03-17 18:42                       ` ben scott
2009-03-17 20:52                       ` Greg Freemyer
2009-03-16 20:28                 ` [linux-lvm] fsync() and LVM Les Mikesell
2009-03-16 20:54                   ` Greg Freemyer
2009-03-16 21:17                     ` Les Mikesell
2009-03-16 21:36                       ` Greg Freemyer
2009-03-16 21:53                         ` Les Mikesell
2009-03-16 22:51                           ` Joshua D. Drake
2009-03-17 15:33                             ` Joshua D. Drake
2009-03-19  9:20                               ` Tim Post [this message]
2009-03-16 21:57                         ` Allen, Jack
2009-03-17 16:00             ` Marco Colombo
2009-03-17 17:40               ` Stuart D. Gathman
2009-03-17 18:17                 ` Les Mikesell
2009-03-18  0:37                   ` Marco Colombo
2009-03-15  8:51         ` Dietmar Maurer
2009-03-15 23:31           ` Marco Colombo
2009-03-17 18:12           ` Les Mikesell
2009-03-17 18:19             ` Dietmar Maurer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1237454458.19345.157.camel@localhost.localdomain \
    --to=echo@echoreply.us \
    --cc=jd@commandprompt.com \
    --cc=linux-lvm@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.