[PATCH 2/3] btrfs-progs: Add a command to show bg info

2016-10-17 Thread Divya Indi
Add a new subcommand to btrfs inspect-internal btrfs inspect-internal bg_analysis Gives information about all the block groups. Signed-off-by: Divya Indi <divya.i...@oracle.com> Reviewed-by: Ashish Samant <ashish.sam...@oracle.com> Reviewed-by: Liu Bo <bo.li@oracle.com> -

[PATCH 1/3] btrfs-progs: Generic functions to retrieve chunks and their bg info

2016-10-17 Thread Divya Indi
An efficient alternative to retrieving block groups: get_chunks(): Walk the chunk tree to retrieve the chunks. get_bg_info(): For each retrieved chunk, lookup an exact match of block group in the extent tree. Signed-off-by: Divya Indi <divya.i...@oracle.com> Reviewed-by: Ashish Samant <a

btrfs-progs: Add 2 new subcommands to inspect-internal

2016-10-17 Thread Divya Indi
These patches aim to add 2 new subcommands that: -> provide information about block groups -> help to decide whether balance can reduce the no. of data block groups and if it can, provides the block group object id for "-dvrange" [PATCH 1/3] btrfs-progs: Generic functions to retrieve chunks and

[PATCH 3/3] btrfs-progs: Add command to check if balance op is req

2016-10-17 Thread Divya Indi
Add new subcommand to btrfs inspect-internal btrfs inspect-internal balance_check Checks whether 'btrfs balance' can help creating more space (Only considers data block groups). Signed-off-by: Divya Indi <divya.i...@oracle.com> Reviewed-by: Ashish Samant <ashish.sam...@oracle.com&

Re: [PATCH 3/3] btrfs-progs: Add command to check if balance op is req

2016-10-19 Thread Divya Indi
On 10/17/2016 06:42 PM, Qu Wenruo wrote: At 10/18/2016 08:35 AM, Divya Indi wrote: Add new subcommand to btrfs inspect-internal btrfs inspect-internal balance_check Checks whether 'btrfs balance' can help creating more space (Only considers data block groups). I didn't think it's good

Re: [PATCH 2/3] btrfs-progs: Add a command to show bg info

2016-10-19 Thread Divya Indi
On 10/17/2016 10:24 PM, Roman Mamedov wrote: On Tue, 18 Oct 2016 09:39:32 +0800 Qu Wenruo wrote: static const char * const cmd_inspect_inode_resolve_usage[] = { "btrfs inspect-internal inode-resolve [-v] ", "Get file system paths for the given

Re: [PATCH 2/3] btrfs-progs: Add a command to show bg info

2016-11-01 Thread divya . indi
On 10/28/2016 09:00 AM, David Sterba wrote: On Mon, Oct 17, 2016 at 05:35:14PM -0700, Divya Indi wrote: Add a new subcommand to btrfs inspect-internal btrfs inspect-internal bg_analysis Gives information about all the block groups. The sample output from the cover letter should also go

Re: [PATCH 1/3] btrfs-progs: Generic functions to retrieve chunks and their bg info

2016-11-01 Thread divya . indi
On 10/28/2016 08:44 AM, David Sterba wrote: On Mon, Oct 17, 2016 at 05:35:13PM -0700, Divya Indi wrote: An efficient alternative to retrieving block groups: get_chunks(): Walk the chunk tree to retrieve the chunks. get_bg_info(): For each retrieved chunk, lookup an exact match of block group

Re: [PATCH 3/3] btrfs-progs: Add command to check if balance op is req

2016-11-01 Thread divya . indi
On 10/31/2016 09:33 AM, David Sterba wrote: On Fri, Oct 28, 2016 at 05:29:45PM +0100, Graham Cobb wrote: On 28/10/16 16:20, David Sterba wrote: I tend to agree with this approach. The usecase, with some random sample balance options: $ btrfs balance start --analyze -dusage=10 -musage=5

Re: [PATCH 1/3] btrfs-progs: Generic functions to retrieve chunks and their bg info

2017-06-09 Thread divya . indi
Hi, Working on a v2 of this patch based on the comments received. Thanks, Divya On 06/07/2017 10:03 AM, Goffredo Baroncelli wrote: Hi, any news about these commands ? BR G.Baroncelli On 2016-10-28 17:44, David Sterba wrote: On Mon, Oct 17, 2016 at 05:35:13PM -0700, Divya Indi wrote