[PATCH] btrfs-progs: doc: fix btrfs-inspect-internal rootid doc

2017-08-24 Thread Misono, Tomohiro
"btrfs inspect-internal rootid " rejects a file to be specified in the implementation. Therefore change "file or directory" to "directory" in the doc. Signed-off-by: Tomohiro Misono --- Documentation/btrfs-inspect-internal.asciidoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [PATCH] btrfs-progs: doc: fix btrfs-inspect-internal rootid doc

2017-08-24 Thread Qu Wenruo
On 2017年08月24日 15:39, Misono, Tomohiro wrote: "btrfs inspect-internal rootid " rejects a file to be specified in the implementation. Therefore change "file or directory" to "directory" in the doc. Signed-off-by: Tomohiro Misono ---   Documentation/btrfs-inspect-internal.asciidoc | 2 +-   1

[PATCH] btrfs-progs: doc: add figure 1 to btrfs quota doc

2017-08-24 Thread Misono, Tomohiro
The document of btrfs quota is missing figure 1. I notice the body is copy of http://sensille.com/qgroups.pdf (whi ch is linked from https://btrfs.wiki.kernel.org/index.php/Quota_support), and insert the figure. Signed-off-by: Tomohiro Misono --- Documentation/btrfs-quota.asciidoc | 18

Re: [PATCH 2/6] raid5: remove a call to get_start_sect

2017-08-24 Thread Christoph Hellwig
On Wed, Aug 23, 2017 at 11:23:38AM -0700, Shaohua Li wrote: > On Wed, Aug 23, 2017 at 07:10:28PM +0200, Christoph Hellwig wrote: > > The block layer always remaps partitions before calling into the > > ->make_request methods of drivers. Thus the call to get_start_sect in > > in_chunk_boundary will

Re: [PATCH] Btrfs: rework outstanding_extents

2017-08-24 Thread Lu Fengqi
On Thu, Aug 17, 2017 at 01:01:29PM -0400, jo...@toxicpanda.com wrote: >From: Josef Bacik > >Right now we do a lot of weird hoops around outstanding_extents in order >to keep the extent count consistent. This is because we logically >transfer the outstanding_extent count from the initial reservati

[PATCH] Btrfs-progs: Check on num_stripes in print_chunk

2017-08-24 Thread zhangyu-fnst
From: Zhang Yu [TEST/fuzz] case: 004-simple-dump-tree Since the wrong key(DATA_RELOC_TREE CHUNK_ITEM 0) in root tree, error calling print_chunk(), resulting in num_stripes == 0. ERROR: [TEST/fuzz] 004-simple-dump-tree ctree.h:317: btrfs_chunk_item_size: BUG_ON `num_stripes == 0`

Re: BTRFS RAID 1 not mountable: open_ctree failed, super_num_devices 3 mismatch with num_devices 2 found here

2017-08-24 Thread Dmitrii Tcvetkov
> I rebootet with HWE K4.11 > > and took a pic of the error message (see attachment). > > It seems btrfs still sees the removed NVME. > There is a mismatch from super_num_devices (3) to num_devices (2) > with indicates something strage is going on here, imho. > > Then i returned and booted K4

Re: [PATCH] Btrfs: do not reset bio->bi_ops while writing bio

2017-08-24 Thread Christoph Hellwig
On Wed, Aug 23, 2017 at 12:15:09PM -0600, Liu Bo wrote: > flush_epd_write_bio() sets bio->bi_ops by itself to honor REQ_SYNC, > but it's not needed at all since bio->bi_ops has set up properly in > both __extent_writepage() and write_one_eb(), and in the case of > write_one_eb(), it also sets REQ_M

Re: [PATCH][v2] btrfs: change how we decide to commit transactions during flushing

2017-08-24 Thread Nikolay Borisov
On 22.08.2017 23:00, jo...@toxicpanda.com wrote: > From: Josef Bacik > > Nikolay reported that generic/273 was failing currently with ENOSPC. > Turns out this is because we get to the point where the outstanding > reservations are greater than the pinned space on the fs. This is a > mistake, p

[GIT PULL] Btrfs fix for rc7

2017-08-24 Thread David Sterba
Hi, we have one more fixup that stems from the blk_status_t conversion that did not quite cover everything. The normal cases were not affected because the code is 0, but any error and retries could mix up new and old values. Please pull, thanks. --

Re: [PATCH] btrfs-progs: fix cross-compile build

2017-08-24 Thread David Sterba
On Wed, Aug 16, 2017 at 08:17:00AM +0800, Qu Wenruo wrote: > > > On 2017年08月16日 02:11, Eric Sandeen wrote: > > The mktables binary needs to be build with the host > > compiler at built time, not the target compiler, because > > it runs at build time to generate the raid tables. > > > > Copy auto

Re: [PATCH 1/3] btrfs-progs: fix option handling for some commands

2017-08-24 Thread David Sterba
On Thu, Aug 24, 2017 at 02:18:25PM +0900, Misono, Tomohiro wrote: > I found some btrfs commands options are not working because of > inappropriate getopt_long() setting. > > This fixes "btrfs check -Q/-E" > > Signed-off-by: Tomohiro Misono Patches 1-3 and the doc fix applied with some changelo

Re: [PATCH] btrfs-progs: doc: fix btrfs-inspect-internal rootid doc

2017-08-24 Thread David Sterba
On Thu, Aug 24, 2017 at 04:39:53PM +0900, Misono, Tomohiro wrote: > "btrfs inspect-internal rootid " rejects a file to be specified in > the implementation. > Therefore change "file or directory" to "directory" in the doc. Is there a reason why a file should not be accepted? The ioctl supports th

Re: number of subvolumes

2017-08-24 Thread Peter Grandi
>> Using hundreds or thousands of snapshots is probably fine >> mostly. As I mentioned previously, with a link to the relevant email describing the details, the real issue is reflinks/backrefs. Usually subvolume and snapshots involve them. > We find that typically apt is very slow on a machine wi

Re: [PATCH] btrfs-progs: doc: add figure 1 to btrfs quota doc

2017-08-24 Thread David Sterba
On Thu, Aug 24, 2017 at 04:48:31PM +0900, Misono, Tomohiro wrote: > The document of btrfs quota is missing figure 1. > > I notice the body is copy of http://sensille.com/qgroups.pdf (whi > ch is linked from > https://btrfs.wiki.kernel.org/index.php/Quota_support), and insert the > figure. > > S

Re: [PATCH] Btrfs: do not reset bio->bi_ops while writing bio

2017-08-24 Thread Liu Bo
On Thu, Aug 24, 2017 at 07:10:41AM -0700, Christoph Hellwig wrote: > On Wed, Aug 23, 2017 at 12:15:09PM -0600, Liu Bo wrote: > > flush_epd_write_bio() sets bio->bi_ops by itself to honor REQ_SYNC, > > but it's not needed at all since bio->bi_ops has set up properly in > > both __extent_writepage()

Re: number of subvolumes

2017-08-24 Thread Marat Khalili
> We find that typically apt is very slow on a machine with 50 or so snapshots > and raid10. Slow as in probably 10x slower as doing the same update on a > machine with 'single' and no snapshots. > > Other operations seem to be the same speed, especially disk benchmarks do not > seem to indicate

[RFC PATCH] Btrfs: handle unaligned tail of data ranges more efficient

2017-08-24 Thread Timofey Titovets
At now while switch page bits in data ranges we always hande +1 page, for cover case where end of data range is not page aligned Let's handle that case more obvious and efficient Check end aligment directly and touch +1 page only then needed Signed-off-by: Timofey Titovets --- fs/btrfs/extent_i

Re: number of subvolumes

2017-08-24 Thread Ferry Toth
Op Thu, 24 Aug 2017 22:40:54 +0300, schreef Marat Khalili: >> We find that typically apt is very slow on a machine with 50 or so >> snapshots and raid10. Slow as in probably 10x slower as doing the same >> update on a machine with 'single' and no snapshots. >> >> Other operations seem to be the sa

Re: [PATCH] btrfs-progs: fix cross-compile build

2017-08-24 Thread Qu Wenruo
On 2017年08月25日 01:01, David Sterba wrote: On Wed, Aug 16, 2017 at 08:17:00AM +0800, Qu Wenruo wrote: On 2017年08月16日 02:11, Eric Sandeen wrote: The mktables binary needs to be build with the host compiler at built time, not the target compiler, because it runs at build time to generate the r

Re: [PATCH] btrfs-progs: doc: fix btrfs-inspect-internal rootid doc

2017-08-24 Thread Misono, Tomohiro
On 2017/08/25 2:37, David Sterba wrote: On Thu, Aug 24, 2017 at 04:39:53PM +0900, Misono, Tomohiro wrote: "btrfs inspect-internal rootid " rejects a file to be specified in the implementation. Therefore change "file or directory" to "directory" in the doc. Is there a reason why a file should n

Re: [PATCH] btrfs-progs: fix cross-compile build

2017-08-24 Thread Eric Sandeen
On 8/24/17 12:01 PM, David Sterba wrote: > On Wed, Aug 16, 2017 at 08:17:00AM +0800, Qu Wenruo wrote: >> >> >> On 2017年08月16日 02:11, Eric Sandeen wrote: >>> The mktables binary needs to be build with the host >>> compiler at built time, not the target compiler, because >>> it runs at build time to

[PATCH] Btrfs: use the new helper wbc_to_write_flags

2017-08-24 Thread Liu Bo
This updates btrfs to use the helper wbc_to_write_flags which has been applied in ext4/xfs/f2fs/block. Please note that, with this, btrfs's dirty pages written by a writeback job will carry the flag REQ_BACKGROUND, which is currently used by writeback-throttle to determine whether it should go to

[PATCH] btrfs: fix NULL pointer dereference from free_reloc_roots()

2017-08-24 Thread Naohiro Aota
__del_reloc_root should be called before freeing up reloc_root->node. If not, calling __del_reloc_root() dereference reloc_root->node, causing the system BUG. Signed-off-by: Naohiro Aota --- fs/btrfs/relocation.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/rel

Re: [PATCH] btrfs: fix NULL pointer dereference from free_reloc_roots()

2017-08-24 Thread Nikolay Borisov
On 25.08.2017 08:15, Naohiro Aota wrote: > __del_reloc_root should be called before freeing up reloc_root->node. > If not, calling __del_reloc_root() dereference reloc_root->node, causing > the system BUG. > > Signed-off-by: Naohiro Aota This patch should also have: Fixes: 6bdf131fac23 ("Btrf

Re: number of subvolumes

2017-08-24 Thread Chris Murphy
On Thu, Aug 24, 2017 at 3:56 PM, Ferry Toth wrote: > Op Thu, 24 Aug 2017 22:40:54 +0300, schreef Marat Khalili: > >>> We find that typically apt is very slow on a machine with 50 or so >>> snapshots and raid10. Slow as in probably 10x slower as doing the same >>> update on a machine with 'single'

Re: [RFC PATCH] Btrfs: handle unaligned tail of data ranges more efficient

2017-08-24 Thread Nikolay Borisov
On 25.08.2017 00:12, Timofey Titovets wrote: > At now while switch page bits in data ranges > we always hande +1 page, for cover case > where end of data range is not page aligned > > Let's handle that case more obvious and efficient > Check end aligment directly and touch +1 page > only then ne