The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Nathan Scott <nathans@sgi.com>
To: Pavel Machek <pavel@ucw.cz>
Cc: kernel list <linux-kernel@vger.kernel.org>,
	"Rafael J. Wysocki" <rjw@sisk.pl>,
	xfs@oss.sgi.com
Subject: Re: XFS vs. swsusp
Date: Tue, 1 Aug 2006 08:41:43 +1000	[thread overview]
Message-ID: <20060801084143.D2286470@wobbly.melbourne.sgi.com> (raw)
In-Reply-To: <20060731215933.GB3612@elf.ucw.cz>; from pavel@ucw.cz on Mon, Jul 31, 2006 at 11:59:33PM +0200

On Mon, Jul 31, 2006 at 11:59:33PM +0200, Pavel Machek wrote:
> Hi!

Hi there,

> Rafael has patches to add bdev freezing to swsusp. I'd like to know if
> they are neccessary (and why).
> 
> 1) Is sync() enough to guarantee that all the data written before sync
> actually reach the platters?
> 
> (Or is it that data only reach the journal? OTOH that would be okay, too).

It ensures file data reaches its final resting place, and that
metadata changes have been logged.  It does not necessarily
ensure that metadata changes have reached their final resting
place (which can be done during log recovery if need be).

A freeze is one way to ensure all metadata will be written out
(and not just to the log, I mean), unmount is another (d'uh),
and remount,ro is a third.

> 2) If we stop all the user proceses and all the kernel threads, is
> that enough to prevent XFS from writing to disk?

Yes, I believe so (if all user processes and kernel threads are
stopped, who else would be left to initiate I/O?).  There is a
timer driven wakeup done on the per-fs xfssyncd kernel threads,
which do background metadata writeout and will write to the log
periodically... but if those processes are all stopped too, you
should be OK.

cheers.

-- 
Nathan

  reply	other threads:[~2006-07-31 22:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-31 21:59 XFS vs. swsusp Pavel Machek
2006-07-31 22:41 ` Nathan Scott [this message]
2006-07-31 22:53   ` Pavel Machek
2006-07-31 23:23     ` Rafael J. Wysocki
2006-08-01  0:47       ` Pavel Machek

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=20060801084143.D2286470@wobbly.melbourne.sgi.com \
    --to=nathans@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=rjw@sisk.pl \
    --cc=xfs@oss.sgi.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox