[PATCH v2] Btrfs: fix a dio write regression

2012-08-22 Thread bo . li . liu
From: Liu Bo This bug is introduced by commit 3b8bde746f6f9bd36a9f05f5f3b6e334318176a9 (Btrfs: lock extents as we map them in DIO). In dio write, we should unlock the section which we didn't do IO on in case that we fall back to buffered write. But we need to not only unlock the section but als

btrfsprogs: cases of snapshot failures

2012-08-22 Thread Jan Engelhardt
Since btrfs does not do recursive atomic snapshots (which I am ok with), I am doing this myself. A handful of suggestions/problems came up. 1. Maybe btrfsprogs could gain an option to do recursive non-atomic snapshots at the userspace level, simply invoking low-level atomic snapshots one by one?

Re: Computer crash, btrfs partition errors

2012-08-22 Thread Not Zippy
Hi The full output of the btrfs-debug-tree is 190MB compressed, did you want it still ? As far as the conditions, I was running a repo sync which I had CTRL-Z, I then got distracted and mistakenly started the sync again (not sure if you are familiar with repo command, it spawns git processes to c

Re: [PATCH] Btrfs: fix a dio write regression

2012-08-22 Thread David Sterba
Hi, a few minor style comments, On Wed, Aug 22, 2012 at 06:11:14PM +0800, bo.li@oracle.com wrote: > --- a/fs/btrfs/inode.c > +++ b/fs/btrfs/inode.c > @@ -5993,10 +5993,24 @@ unlock: >* in the case of read we need to unlock only the end area that we >* aren't using if there is

Re: raw partition or LV for btrfs?

2012-08-22 Thread David Sterba
On Tue, Aug 14, 2012 at 07:23:48AM -0400, Calvin Walton wrote: > A patch to add support for `btrfs fi defrag -c none ` or so would > make this easier, and shouldn't be to hard to do :) This one is on my list of 'nice to have', it's needed to extend the ioctl to understand 'none' as to actually use

Re: linux 3.5.0: BTRFS error in compress_file_range:581 (failed to join transaction)

2012-08-22 Thread David Sterba
On Tue, Aug 14, 2012 at 09:00:53PM -0700, Marc MERLIN wrote: > > What does the 'ret' shows? Is it -ENOSPC? > > I got nothing else in my logs. Unless it was a second error from a filesystem that went RO, there should be more than the "Failed to join transaction" message, and the first occurence o

Re: Hung I/O, Kernel BUG with corrupt leaf (bad key order)

2012-08-22 Thread David Sterba
On Tue, Aug 14, 2012 at 01:20:36PM -0500, Peter Marheine wrote: > Hi all, > > I'm running btrfs in a 3-disk RAID1 configuration. After a hard > power-off, I'm seeing a lot of hung I/O tasks on this volume, > apparently due to a corrupt leaf. I first noticed the problem on > kernel 3.4.7, and it's

Re: How to get Btrfs on 2nd partition of USB HDD to automount as read/write

2012-08-22 Thread David Sterba
On Tue, Aug 21, 2012 at 03:28:22PM -0400, dg1727 wrote: > Thanks a lot for these answers. As an exercise, how would I track > that patch so I can tell when it has been released? Pointing me to > a webpage that covers this would be fine. You can easily check that the patch appears in the main

Re: Computer crash, btrfs partition errors

2012-08-22 Thread David Sterba
On Tue, Aug 21, 2012 at 09:50:58AM -0700, Not Zippy wrote: > Thanks for the analysis, unfortunately I get the same assert error > when I attempt to run the repair from the compiled source. > > # ./work/builds/btrfs-progs/btrfsck > usage: btrfsck dev > Btrfs Btrfs v0.19 'git describe' would be mor

Re: [PATCH] Btrfs-progs: seg fault in get_label_unmounted

2012-08-22 Thread David Sterba
On Wed, Aug 15, 2012 at 04:29:53PM +0800, Anand jain wrote: > From: Anand Jain > > btrfs f l / > No valid Btrfs found on / > Segmentation fault (core dumped) Patches fixing this have been sent like 4 times, last one was from Alexander's 'btrfs prop', that modified it a bit more (to return the la

interaction with hardware RAID?

2012-08-22 Thread Daniel Pocock
It is well documented that btrfs data recovery (after silent corruption) is dependent on the use of btrfs's own RAID1. However, I'm curious about whether any hardware RAID vendors are contemplating ways to integrate more closely with btrfs, for example, such that when btrfs detects a bad checks

Re: [GIT PULL v2] Update LZO compression

2012-08-22 Thread Johannes Stezenbach
On Tue, Aug 21, 2012 at 05:21:50PM +0200, Markus F.X.J. Oberhumer wrote: > as suggested on the mailing list I have converted the updated LZO > code into git, so please pull my "lzo-update" branch from ... > [ Changes in v2: Optimize code for CPUs with inefficient unaligned > access => significant

[PATCH] Btrfs: fix a dio write regression

2012-08-22 Thread bo . li . liu
From: Liu Bo This bug is introduced by commit 3b8bde746f6f9bd36a9f05f5f3b6e334318176a9 (Btrfs: lock extents as we map them in DIO). In dio write, we should unlock the section which we didn't do IO on in case that we fall back to buffered write. But we need to not only unlock the section but als