On 02/10/2015 07:24 PM, Filipe David Manana wrote:
On Tue, Feb 10, 2015 at 10:24 AM, Dongsheng Yang
yangds.f...@cn.fujitsu.com wrote:
In function of __btrfs_mod_ref(), we are passing the no_quota=1
to process_func() anyway. It will make the numbers in qgroup be
wrong when deleting a subvolume.
Original Message
Subject: [PATCH] btrfs-progs: Fix 2 extent buffer leak in btrfs-debug-tree.
From: Qu Wenruo quwen...@cn.fujitsu.com
To: linux-btrfs@vger.kernel.org
Date: 2015年02月11日 09:57
There are 2 known extent buffer:
Oh, a small typo: 2 known extent buffer leak:, missing
Hi, Liu
Removing large amount of block group in a transaction may encounters
BUG_ON() in btrfs_orphan_add(). That is becuase
btrfs_orphan_reserve_metadata()
Not big matter,
s/becuase/because
Thanks
Zhaolei
will grab metadata reservation from transaction handle, and
Good morning,
these days I am encountering severe problems with at least two btrfs
subvolumes of a raid1 volume.
The problems started after a regular dist-upgrade on a machine running
Ubuntu 14.04 with kernel 3.16.7-031607-generic.
As maybe the following issue with Virtualbox (VB) is
Hi all,
[1/9] is a RESEND with a reviewed-by.
[2/9]-[6/9] are bug fixes about qgroup_inherit(), these patch make
user can set the limits when creating a subvolume with the related
patch in userspace applied.
[7/9]-[8/9] are a cleanup for qgroup.
[9/9] provides a way for btrfs-progs to get the
From: Fan Chengniang fancn.f...@cn.fujitsu.com
add a function to obtain quota status. Now it can only get
whether quota is enabled. We can extend the function to get
more quota status
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
---
fs/btrfs/ioctl.c | 6 ++
When we commit_transaction(), qgroups in btree should be updated.
But, limit info is not considered currently. It will cause a problem
when a qgroup of a snapshot inherit the limit info from srcqgroup,
then there is an inconsistency.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
There are two problems in qgroup:
a). The PAGE_CACHE is 4K, even when we are writing a data of 1K,
qgroup will reserve a 4K size. It will cause the last 3K in a qgroup
is not available to user.
b). When user is writing a inline data, qgroup will not reserve it,
it means this is a window we can
Cleanup: Change the parameter of update_qgroup_limit_item() to the family of
update_qgroup_xxx_item().
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 51 ---
1 file changed, 24 insertions(+), 27 deletions(-)
diff
From: Fan Chengniang fancn.f...@cn.fujitsu.com
the return values 12 and 13 are not used spectially except as
return value. No description and definition about them. so I
change them to generic errno
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
---
qgroup.c | 7 ---
1 file
When we create a subvol inheriting a qgroup, we need to check the level
of them. Otherwise, there is a chance a qgroup can inherit another qgroup
at the same level.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 5 +
1 file changed, 5 insertions(+)
diff
In function of __btrfs_mod_ref(), we are passing the no_quota=1
to process_func() anyway. It will make the numbers in qgroup be
wrong when deleting a subvolume. The data size in a deleted subvolume
will never be decressed from all related qgroups.
Signed-off-by: Dongsheng Yang
From: Fan Chengniang fancn.f...@cn.fujitsu.com
add -r and -e options to enable setting max reference size
and max exclusive on creating new subvolumes.
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
---
Documentation/btrfs-subvolume.txt | 8 +++-
cmds-qgroup.c | 42
Hi all,
This is part2 for qgroup. It is based on
[PATCH 0/9] Btrfs: qgroup: part-1: bug fixes.
[1/4] is reviewed-by Josef.
[2/4] - [4/4] are trying to solve a problem in qgroup reservation.
It would be weired I introduce a may_use in 2/4 and delete it in 4/4.
Yes, I am glad to
When we call btrfs_qgroup_inherit() with BTRFS_QGROUP_INHERIT_SET_LIMITS,
btrfs will update the limit info of qgroup in btree but forget to update
the qgroup in rbtree at the same time. It obviousely will cause an
inconsistency.
This patch fix it by updating the rbtree at the same time.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/ioctl.c | 3 +--
fs/btrfs/qgroup.c | 2 +-
fs/btrfs/qgroup.h | 3 +--
fs/btrfs/tests/qgroup-tests.c | 4 ++--
4 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/fs/btrfs/ioctl.c
Hi all,
This is a part3 for qgroup, it is based on
Btrfs: qgroup: part-2: bug fixes.
Dongsheng Yang (3):
btrfs: qgroup: return EINVAL if level of parent is not higher than
child's.
btrfs: qgroup: allow to remove qgroup which has parent but no child.
btrfs: qgroup: fix a
Currently, when we snapshot a subvol, snapshot will not copy the limits
from srcqgroup.
This patch make the qgroup in snapshot inherit the limit info when create
a snapshot.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 8
1 file changed, 8
In function qgroup_excl_accounting(), we need to WARN when
qg-excl is less than what we want to free, same to child
and parents. But currently, for parent qgroup, the WARN_ON()
is located after freeing qg-excl. It will WARN out even we
free it normally.
This patch move this WARN_ON() before
It's not a big deal, but I would rather make the btree follow the
convention to increase from left to right.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/fs/btrfs/qgroup.c
btrfs_limit_group use arg limit to override the old qgroup_limit of
corresponding qgroup. However, we should override part of old qgroup_limit
according to the bit which has been set in arg limit.
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
Signed-off-by: Dongsheng Yang
Although we have a type in each qgroup, the all qgroups
are created in a default mode. This patch provide a
method to user to specify the type of qgroup for a sub volume.
It uses an unused byte in btrfs_ioctl_vol_args_v2 to pass
a qgroup type from userspace to kernel. Then kernel can
create a
Currenly, in data writing, -reserved is accounted in
fill_delalloc(), but -may_use is released in clear_bit_hook()
which is called by btrfs_finish_ordered_io(). That's too late,
that said, between fill_delalloc() and btrfs_finish_ordered_io(),
the data is doublely accounted by qgroup. It will
Currently, for pre_alloc or delay_alloc, the bytes will be accounted
in space_info by the three guys.
space_info-bytes_may_use --- space_info-reserved --- space_info-used.
But on the other hand, in qgroup, there are only two counters to account the
bytes, qgroup-reserved and qgroup-excl. And
From: Fan Chengniang fancn.f...@cn.fujitsu.com
make 'btrfs qgroup show' command show qgroup type.
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
---
qgroup.c | 42 +++---
qgroup.h | 1 +
2 files changed, 40 insertions(+), 3 deletions(-)
diff --git
From: Fan Chengniang fancn.f...@cn.fujitsu.com
add --qgroup-type option to specify qgroup type. Type
can be metadata, data or mixed.
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
Documentation/btrfs-qgroup.txt | 5 +
Now, we have a type in each qgroup, then when we do a inherit(),
we need to consider the type of qgroup to decide account metadata
or not.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 18 ++
1 file changed, 14 insertions(+), 4 deletions(-)
This patch provide a method to user to create a qgroup
in a specified type.
It use a byte of the -create in btrfs_ioctl_qgroup_create_args
to pass the type of qgroup to kernel. Then there is a macro
named as BTRFS_QGROUP_TYPE_SHIFT to help kernel get the type
of qgroup user want to creat.
Hi all,
This patchset is based on [Btrfs: qgroup: part-3: bug fixes.]
I am introducing a type to qgroup, then we can get the numbers what we
only care about.
Easy way to get the code for testing:
btrfs: https://yangdongsh...@github.com/yangdongsheng/linux.git
qgroup_type
From: Fan Chengniang fancn.f...@cn.fujitsu.com
add --qgroup-type option to specify qgroup type. Type
can be metadata, data or all.
Signed-off-by: Fan Chengniang fancn.f...@cn.fujitsu.com
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
Documentation/btrfs-subvolume.txt | 4
Although we have different type for each qgroup now,
but the rescan is also working as before which is considering
data and metadata both.
This patch fix this problem.
Signed-off-by: Dongsheng Yang yangds.f...@cn.fujitsu.com
---
fs/btrfs/qgroup.c | 19 ++-
1 file changed, 14
This patch is introducing a *type* to btrfs_qgroup.
Type could be data, metadata or both. data means this
qgroup only care about the data size, metadata means
this qgroup only care about the metadata size and both
means this qgroup will care about data and metadata like
what it was doing before
On Mon, Feb 09, 2015 at 02:11:52PM +0800, Qu Wenruo wrote:
Although fsck-test/012 uses sudo, it uses 'sudo -n', which won't prompt
user to input password and will return 1 if no valid credential is
found.
And this makes test result quite annoying since it fails to mount and
still continue,
2015-02-10 8:17 GMT+01:00 Kai Krakow hurikha...@gmail.com:
Tobias Holst to...@tobby.eu schrieb:
and btrfs scrub status /[device] gives me the following output:
scrub status for [UUID]
scrub started at Mon Feb 9 18:16:38 2015 and was aborted after 2008
seconds total bytes scrubbed: 113.04GiB
On 02/10/2015 02:14 PM, David Sterba wrote:
On Mon, Feb 09, 2015 at 03:03:12PM -0500, Josef Bacik wrote:
The METADUMP super flag makes us skip doing the chunk tree reading which isn't
helpful for the new restore since we have a valid chunk tree. But we still want
to have a way for the kernel
Removing large amount of block group in a transaction may encounters
BUG_ON() in btrfs_orphan_add(). That is because btrfs_orphan_reserve_metadata()
will grab metadata reservation from transaction handle, and
btrfs_delete_unused_bgs() didn't reserve metadata for trnasaction handle when
delete
Original Message
Subject: Re: [PATCH] btrfs-progs: fsck-test: Add check_sudo to check
valid root/sudo privilege
From: David Sterba dste...@suse.cz
To: Qu Wenruo quwen...@cn.fujitsu.com
Date: 2015年02月10日 21:30
On Mon, Feb 09, 2015 at 02:11:52PM +0800, Qu Wenruo wrote:
Original Message
Subject: Re: [PATCH v3 00/10] Enhance btrfs-find-root and open_ctree()
to provide better chance on damaged btrfs.
From: David Sterba dste...@suse.cz
To: Qu Wenruo quwen...@cn.fujitsu.com
Date: 2015年02月10日 22:48
On Thu, Jan 29, 2015 at 05:07:15PM +0800, Qu
Same thing as clang cleanup patch:
commit 040b3f11ba6bd793a9ef79ed4d9032d22370
Author: Qu Wenruo quwen...@cn.fujitsu.com
Date: Fri Dec 19 14:13:08 2014 +0800
btrfs-progs: Makefile: Move linker only option to LDFLAGS
But the move to autoconfig seems using old Makefile.
So do it again.
39 matches
Mail list logo