[bug] btrfs-progs-v4.8.4: test of 'btrfs receive' in xfstests fails

2016-11-27 Thread Tsutomu Itoh
Hi, David, Many test of xfstests such as btrfs/007, btrfs/008 and btrfs/016 failed with the following patch. fefbab75 btrfs-progs: send-stream: check number of read bytes from stream This is because cmds-receive.c:do_receive() make a judgement of the end of stream by returning 1 from

[PATCH] btrfs: fix hole read corruption for compressed inline extents

2016-11-27 Thread Zygo Blaxell
Commit c8b978188c ("Btrfs: Add zlib compression support") produces data corruption when reading a file with a hole positioned after an inline extent. btrfs_get_extent will return uninitialized kernel memory instead of zero bytes in the hole. Commit 93c82d5750 ("Btrfs: zero page past end of

Re: [PATCH] btrfs: raid56: Use correct stolen pages to calculate P/Q

2016-11-27 Thread Christoph Anton Mitterer
On Mon, 2016-11-28 at 06:53 +0300, Andrei Borzenkov wrote: > If you allow any write to filesystem before resuming from hibernation > you risk corrupted filesystem. I strongly believe that "ro" must be > really read-only You're aware that "ro" already doesn't mean "no changes to the block device"

Re: [PATCH] btrfs: raid56: Use correct stolen pages to calculate P/Q

2016-11-27 Thread Andrei Borzenkov
28.11.2016 06:37, Christoph Anton Mitterer пишет: > On Sat, 2016-11-26 at 14:12 +0100, Goffredo Baroncelli wrote: >> I cant agree. If the filesystem is mounted read-only this behavior >> may be correct; bur in others cases I don't see any reason to not >> correct wrong data even in the read case.

Re: [PATCH] btrfs: raid56: Use correct stolen pages to calculate P/Q

2016-11-27 Thread Christoph Anton Mitterer
On Sat, 2016-11-26 at 14:12 +0100, Goffredo Baroncelli wrote: > I cant agree. If the filesystem is mounted read-only this behavior > may be correct; bur in others cases I don't see any reason to not > correct wrong data even in the read case. If your ram is unreliable > you have big problem

Re: [RFC PATCH 0/3] Add testcase for fundamental scrub recovery

2016-11-27 Thread Eryu Guan
On Mon, Nov 28, 2016 at 10:50:30AM +0800, Qu Wenruo wrote: > Any comment? Sorry for the late review, I'm planning to look at them this week. Thanks, Eryu -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vger.kernel.org More majordomo

Re: mount option nodatacow for VMs on SSD?

2016-11-27 Thread Duncan
Ulli Horlacher posted on Mon, 28 Nov 2016 01:38:29 +0100 as excerpted: > Ok, then next question :-) > > What is better (for a single user workstation): using mount option > "autodefrag" or call "btrfs filesystem defragment -r" (-t ?) via nightly > cronjob? > > So far, I use neither. First

Re: [RFC PATCH 0/3] Add testcase for fundamental scrub recovery

2016-11-27 Thread Qu Wenruo
Any comment? At 11/22/2016 04:38 PM, Qu Wenruo wrote: Despite the scrub test cases in fstests, there is not even one test case which really checked if scrub can recover data. In fact, btrfs scrub for RAID56 will even corrupt correct data stripes. So let's start from the needed facilities and

Re: WARNING at extent-tree.c:6945 __btrfs_free_extent.isra.33+0x7d6/0xca0 (Linux 4.8.0)

2016-11-27 Thread Dāvis Mosāns
2016-10-19 14:16 GMT+03:00 Dāvis Mosāns : > > Basically on multi-disk btrfs partition few sectors on one HDD became > unreadable and when trying to delete one folder on that filesystem I > got this in log > [...] dmesg now on 4.8.11 [ 3825.603883] WARNING: CPU: 5 PID: 15736

[PATCH v4 3/3] btrfs: qgroup: Re-arrange tracepoint timing to co-operate with reserved space tracepoint

2016-11-27 Thread Qu Wenruo
Newly introduced qgroup reserved space trace points are normally nested into several common qgroup operations. While some other trace points are not well placed to co-operate with them, causing confusing output. This patch re-arrange trace_btrfs_qgroup_release_data() and

[PATCH v4 1/3] btrfs: Add WARN_ON for qgroup reserved underflow

2016-11-27 Thread Qu Wenruo
Goldwyn Rodrigues has exposed and fixed a bug which underflows btrfs qgroup reserved space, and leads to non-writable fs. This reminds us that we don't have enough underflow check for qgroup reserved space. For underflow case, we should not really underflow the numbers but warn and keeps qgroup

[PATCH v4 2/3] btrfs: Add trace point for qgroup reserved space

2016-11-27 Thread Qu Wenruo
Introduce the following trace points: qgroup_update_reserve qgroup_meta_reserve These trace points are handy to trace qgroup reserve space related problems. Signed-off-by: Qu Wenruo --- v2: None v3: Separate from trace point timing modification patch. v4: Change

Re: [PATCH] btrfs: raid56: Use correct stolen pages to calculate P/Q

2016-11-27 Thread Qu Wenruo
At 11/27/2016 07:16 AM, Goffredo Baroncelli wrote: On 2016-11-26 19:54, Zygo Blaxell wrote: On Sat, Nov 26, 2016 at 02:12:56PM +0100, Goffredo Baroncelli wrote: On 2016-11-25 05:31, Zygo Blaxell wrote: [...] BTW Btrfs in RAID1 mode corrects the data even in the read case. So Have you

Re: mount option nodatacow for VMs on SSD?

2016-11-27 Thread Ulli Horlacher
On Sat 2016-11-26 (11:27), Kai Krakow wrote: > > I have vmware and virtualbox VMs on btrfs SSD. > As a side note: I don't think you can use "nodatacow" just for one > subvolume while the other subvolumes of the same btrfs are mounted > different. The wiki is just wrong here. > > The list of

Re: [PATCH 00/19] Offline scrub support

2016-11-27 Thread Qu Wenruo
At 11/26/2016 02:26 AM, David Sterba wrote: Hi, I have comments regarding the code organization, not really the raid56 functionality itself. Thanks for the comment. On Fri, Oct 28, 2016 at 10:31:36AM +0800, Qu Wenruo wrote: For any one who wants to try it, it can be get from my repo:

Re: [CORRUPTION FILESYSTEM] Corrupted and unrecoverable file system during the snapshot receive

2016-11-27 Thread Giuseppe Della Bianca
I have reinstalled from scratch my system (for remote receiving of the snapshot). Now it uses the 4.8.8-100.fc23.x86_64 kernel, and now I have a separate partition for '''possible dangerous''' test. I do not remember the exact sequence that caused the corruption of the file system, but now it

Re: [PATCH] btrfs: raid56: Use correct stolen pages to calculate P/Q

2016-11-27 Thread Zygo Blaxell
On Sun, Nov 27, 2016 at 12:16:34AM +0100, Goffredo Baroncelli wrote: > On 2016-11-26 19:54, Zygo Blaxell wrote: > > On Sat, Nov 26, 2016 at 02:12:56PM +0100, Goffredo Baroncelli wrote: > >> On 2016-11-25 05:31, Zygo Blaxell wrote: > [...] > >> > >> BTW Btrfs in RAID1 mode corrects the data even in