Re: [PATCH 2.6.19 5/5] fs: freeze_bdev with semaphore not mutex



Hi!

This means, however, that we can leave the patch as is (well, with the minor
fix I have already posted), for now, because it doesn't make things worse a
bit, but:
(a) it prevents xfs from being corrupted and

I'd really prefer it to be fixed by 'freezeable workqueues'.

I'd prefer that you just freeze the filesystem and let the
filesystem do things correctly.

Well, I'd prefer filesystems not to know about suspend, and current
"freeze the filesystem" does not really nest properly.

Can you
point me into sources -- which xfs workqueues are problematic?

AFAIK, its the I/O completion workqueues that are causing problems.
(fs/xfs/linux-2.6/xfs_buf.c) However, thinking about it, I'm not
sure that the work queues being left unfrozen is the real problem.

i.e. after a sync there's still I/O outstanding (e.g. metadata in
the log but not on disk), and because the kernel threads are frozen
some time after the sync, we could have issued this delayed write
metadata to disk after the sync. With XFS, we can have a of queue of

That's okay, snapshot is atomic. As long as data are safely in the
journal, we should be okay.

However, even if you stop the workqueue processing, you're still
going to have to wait for all I/O completion to occur before
snapshotting memory because having any I/O complete changes memory
state. Hence I fail to see how freezing the workqueues really helps
at all here....

It is okay to change memory state, just on disk state may not change
after atomic snapshot.
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: [PATCH 2.6.19 5/5] fs: freeze_bdev with semaphore not mutex
    ... I'd really prefer it to be fixed by 'freezeable workqueues'. ... I'd prefer that you just freeze the filesystem and let the ... its the I/O completion workqueues that are causing problems. ... snapshotting memory because having any I/O complete changes memory ...
    (Linux-Kernel)
  • [OOPS] amrestore dies in pfn_to_page 2.6.16-gentoo-r7 (x86_64)
    ... I've also had problems restoring large XFS partitions off of tape ... # ACPI Support ... # CPU Frequency scaling ...
    (Linux-Kernel)
  • XFS kernel crash
    ... To me it looks like a problem in the XFS filesystem and I consider defects in filesystem very, ... (ACPI NVS) ... SCSI device sdb: 20971520 512-byte hdwr sectors ...
    (Linux-Kernel)
  • Re: XFS filesystem corruption on the arm(el) architecture
    ... I discovered some problems with xfs. ... I conserved a image of the corrupted filesystem ... Mount the filesystem to replay the log, ... agno = 0 ...
    (Linux-Kernel)
  • Re: ext3 or xfs for desktop laptop
    ... seperate ext2 partition using xfs. ... v4.xxx of the filesystem format. ... And will not be *USING* any reiserfs in production, ... support, should you use them. ...
    (Debian-User)