Re: [PATCH] btrfs: remove empty fs_devices to prevent memory runout

2014-11-21 Thread Anand Jain
Hi Gui, Thanks for attempting this. There was this patch previously attempted for the same problem, which I had to nack.. [PATCH 1/2] btrfs: device list could grow infinite I haven't seen your fix in full yet, But looks like you are using dev_t to suffice the problem of identifying

[PATCH RFC] btrfs: add sysfs layout to show volume info

2014-11-24 Thread Anand Jain
total_bytes type uuid* writeable (* indicates that attribute will be visible even when device is unmounted but registered with btrfs kernel) Signed-off-by: Anand Jain anand.j...@oracle.com --- fs/btrfs

[PATCH RFC v2] btrfs: add sysfs layout to show volume info

2014-12-01 Thread Anand Jain
From: Anand Jain anand.j...@oracle.com Not yet ready for integration, but for review and testing of the new sysfs layout which is currently under /sys/fs/btrfs/by_fsid This patch makes btrfs_fs_devices and btrfs_device information readable from sysfs. This uses the sysfs group visible entry

Re: [PATCH RFC v2] btrfs: add sysfs layout to show volume info

2014-12-01 Thread anand jain
Hi Goffredo, inline below.. On 02/12/2014 01:29, Goffredo Baroncelli wrote: Hi Anand, On 12/01/2014 06:33 PM, Anand Jain wrote: From: Anand Jain anand.j...@oracle.com Not yet ready for integration, but for review and testing of the new sysfs layout which is currently under /sys/fs/btrfs

Re: PROBLEM: #89121 BTRFS mixes up mounted devices with their snapshots

2014-12-02 Thread Anand Jain
, with b96de000b, tried to fix it; however further regression appeared and Chris reverted this commit (see below). BR G.Baroncelli commit b96de000bc8bc9688b3a2abea4332bd57648a49f Author: Anand Jain anand.j...@oracle.com Date: Thu Jul 3 18:22:05 2014 +0800 Btrfs: device_list_add() should not update

Re: [RFC][PATCH v2] mount.btrfs helper

2014-12-03 Thread Anand Jain
On 01/12/2014 01:43, Goffredo Baroncelli wrote: Hi all, this patch provides a mount.btrfs helper for the mount command. A btrfs filesystem could span several disks. This helper scans all the partitions to discover all the disks required to mount a filesystem. So it would not necessary

Re: [RFC][PATCH v2] mount.btrfs helper

2014-12-04 Thread Anand Jain
On 05/12/2014 01:58, Goffredo Baroncelli wrote: On 12/04/2014 03:09 AM, Anand Jain wrote: On 01/12/2014 01:43, Goffredo Baroncelli wrote: Hi all, this patch provides a mount.btrfs helper for the mount command. A btrfs filesystem could span several disks. This helper scans all

Re: Device only missing if unmounted

2014-12-09 Thread Anand Jain
On 09/12/2014 19:15, Florian Uekermann wrote: I am using a few disks in Raid1 mode. This is the output of various commands in unmounted state. root@oot:/# uname -a Linux oot 3.18.0-rc5+ #1 SMP Sun Nov 23 18:01:56 CET 2014 x86_64 GNU/Linux root@oot:/# btrfs --version Btrfs v3.17 root@oot:/#

Re: btrfs scrub status misreports as interrupted

2014-12-09 Thread Anand Jain
Is there any relevant log in the dmegs ? On 09/12/2014 20:16, Konstantinos Skarlatos wrote: I've got the exact same problem, with a 4 drive RAID1. kernel 3.18-git and btrfs tools-git, all built yesterday. On 22/11/2014 2:13 μμ, Marc Joliet wrote: Hi all, While I haven't gotten any scrub

Re: PROBLEM: #89121 BTRFS mixes up mounted devices with their snapshots

2014-12-09 Thread Anand Jain
is detected and its metadata is identical to one already mounted, just ignore it. Seems like patch: commit b96de000bc8bc9688b3a2abea4332bd57648a49f Author: Anand Jain anand.j...@oracle.com Date: Thu Jul 3 18:22:05 2014 +0800 Btrfs: device_list_add() should not update list when mounted

Re: [PATCH V2][BTRFS-PROGS] Don't use LVM snapshot device

2014-12-09 Thread Anand Jain
This patch allows btrfs to skip LVM snapshot during the device scan phase. Its better to generalize the problem and fix it. The fix here is very specific to LVM use case. This does not work in cases where device is cloned using dd (device is unmounted). As mentioned we need to depend on

Re: Device only missing if unmounted

2014-12-17 Thread Anand Jain
I checked this for all three devices and num_devices is 4 for all of them. The full output is below. so now if you mount and run 'btrfs fi show mnt' that should tell device missing, which then 'btrfs device missing mnt' should be successful theoretically. It may fail if you are mounting

Re: [PATCH V2][BTRFS-PROGS] Improve output of mkfs.btrfs command

2014-12-17 Thread Anand Jain
This is nice ! Can I suggest you to take care of 'btrfs fi show' output as well :-) it needs a similar revamp. Earlier I tried to add group profile into the show output but that broke xfstest cases depending on it. so just a note. Thanks, Anand On 18/12/2014 04:14, Goffredo Baroncelli

Re: btrfs doesn't format eMMC if previous filesystem is ext4

2014-12-28 Thread Anand Jain
On 12/26/2014 11:24 PM, Ankur Tank wrote: Hi, I wanted to test btrfs on the eMMC of beaglebone black based custom board. Precondition: eMMC is formatted with ext4 filesystem Use case: Format eMMC with mkfs.btrfs -L label dev Result: Mkfs.btrfs denies formatting eMMC

Re: btrfs doesn't format eMMC if previous filesystem is ext4

2014-12-29 Thread Anand Jain
allow formatting eMMC to btrfs filesytem. Regards, Ankur -Original Message- From: Anand Jain [mailto:anand.j...@oracle.com] Sent: Monday, December 29, 2014 8:21 AM To: Ankur Tank; linux-btrfs@vger.kernel.org Subject: Re: btrfs doesn't format eMMC if previous filesystem is ext4 On 12/26/2014

[PATCH 1/8] Btrfs-progs: move open_file_or_dir() to utils.c

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com The definition of the function open_file_or_dir() is moved from common.c to utils.c in order to be able to share some common code between scrub and the device stats in the following step. That common code uses open_file_or_dir(). Since open_file_or_dir

[PATCH 2/8] Btrfs-progs: Move printing outside of btrfs_list_subvols

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com its better to have btrfs_list_subvols just return witout printing so that btrfs_list_subvols can be reused. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h |2 +- cmds

[PATCH 4/8] Btrfs-progs: move struct root_info to btrfs-list.h

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47 ++- 2 files changed, 46 insertions(+), 48 deletions(-) diff --git

[PATCH 5/8] Btrfs-progs: function to get root_info of a subvol

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 37 + btrfs-list.h |1 + 2 files changed, 38 insertions(+), 0 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index 1851f3e..cb458f1 100644

[PATCH 7/8] Btrfs-progs: add method to filter snapshots by parent uuid

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c |6 ++ btrfs-list.h |1 + 2 files changed, 7 insertions(+), 0 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index 308b54c..efce966 100644 --- a/btrfs-list.c +++ b/btrfs

[PATCH 3/8] Btrfs-progs: add parent uuid for snapshots

2012-12-27 Thread Anand jain
From: Anand Jain anand.j...@oracle.com Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 32 +++- btrfs-list.h |1 + cmds-subvolume.c |6 +- 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/btrfs-list.c b/btrfs

Re: determining filesystem mount points

2012-12-30 Thread Anand Jain
Perhaps the best solution would be to have an option to btrfs subvol list to give output with fully qualified paths. This patch does that. http://comments.gmane.org/gmane.comp.file-systems.btrfs/20040 -Anand -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in

[PATCH 01/11] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-10 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile |4 ++-- btrfsctl.c |7 --- cmds-balance.c |1 + cmds-inspect.c |1 + cmds-qgroup.c

[PATCH 09/11] Btrfs-progs: maintain similar case in heading prefix

2013-01-10 Thread Anand Jain
btrfs su list -qu /btrfs ID 256 gen 35 top level 5 parent_uuid - uuid 60e54c4a-8136-3c43-a107-ea42052c6240 path sv1 ID 257 gen 35 top level 5 parent_uuid 60e54c4a-8136-3c43-a107-ea42052c6240 uuid fdefa4a9-5b67-4f4c-8a11-c43acec51d43 path ss1 Signed-off-by: Anand Jain anand.j...@oracle.com

[PATCH 10/11] Btrfs-progs: accommodate different layout for printing subvol list

2013-01-10 Thread Anand Jain
the printing to other formats. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 26 +++--- btrfs-list.h |3 +++ cmds-subvolume.c | 23 --- 3 files changed, 38 insertions(+), 14 deletions(-) diff --git a/btrfs-list.c b/btrfs

[PATCH 03/11] Btrfs-progs: add parent uuid for snapshots

2013-01-10 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 32 +++- btrfs-list.h |1 + cmds-subvolume.c |6 +- 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b656286..cc065e9 100644

[PATCH 02/11] Btrfs-progs: Move printing outside of btrfs_list_subvols

2013-01-10 Thread Anand Jain
its better to have btrfs_list_subvols just return witout printing so that btrfs_list_subvols can be reused. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h |2 +- cmds-subvolume.c |4 ++-- 3 files changed, 21

[PATCH 05/11] Btrfs-progs: function to get root_info of a subvol

2013-01-10 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 37 + btrfs-list.h |1 + 2 files changed, 38 insertions(+), 0 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index 1851f3e..cb458f1 100644 --- a/btrfs-list.c +++ b/btrfs-list.c

[PATCH 04/11] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-10 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47 ++- 2 files changed, 46 insertions(+), 48 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index cc065e9

[PATCH 08/11] Btrfs-progs: put find_mount_root() in commands.h

2013-01-10 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup(int argc, char **argv

[PATCH 06/11] Btrfs-progs: provide method to check if filter is set

2013-01-10 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 11 +++ btrfs-list.h |2 ++ 2 files changed, 13 insertions(+), 0 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index cb458f1..308b54c 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1181,6 +1181,17 @@ void

Re: [PATCH 3/3] btrfs-progs: add send-test

2013-01-11 Thread Anand Jain
Thanks for libbtrfs. comments below. On 01/09/2013 05:41 AM, Mark Fasheh wrote: send-test.c links against libbtrfs and uses the send functionality provided to decode and print a send stream to the console. We use the BTRFS_SEND_FLAG_NO_FILE_DATA flag as actual file data is never needed for

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-11 Thread Anand Jain
Mark, test case : make (Do not run make all) make install generates the following error.. install -m755 -d /usr/local/lib install libbtrfs.so.1.0 libbtrfs.so.1 libbtrfs.so /usr/local/lib install: cannot stat `libbtrfs.so.1.0': No such file or directory install: cannot stat `libbtrfs.so.1':

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-13 Thread Anand Jain
at 05:31:09PM +0800, Anand Jain wrote: Mark, test case : make (Do not run make all) make install Thanks for testing! generates the following error.. install -m755 -d /usr/local/lib install libbtrfs.so.1.0 libbtrfs.so.1 libbtrfs.so /usr/local/lib install: cannot stat `libbtrfs.so.1.0

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-13 Thread Anand Jain
Mark, Good to create man libbtrfs ? Thanks, Anand On 01/09/2013 05:41 AM, Mark Fasheh wrote: External software wanting to use the functionality provided by the btrfs send ioctl has a hard time doing so without replicating tons of work. Of particular interest are functions like

Re: [PATCH 00/11 V3] add show command to the subvol sub command

2013-01-13 Thread Anand Jain
Any comments on this new sub-command, please. ? Thanks, Anand On 01/10/2013 07:41 PM, Anand Jain wrote: This is an attempt to make btrfs cli more end user friendly. And adds show subcommand to display all known (as of now) information of the given subvol including its snapshot(s

Re: [PATCH 00/11 V3] add show command to the subvol sub command

2013-01-14 Thread Anand Jain
is good to have for btrfs su show / ? Anand On 01/15/2013 02:25 AM, Goffredo Baroncelli wrote: On 01/14/2013 05:04 AM, Anand Jain wrote: Any comments on this new sub-command, please. ? Thanks, Anand I am trying to use this new command. Very nice. However I tried to use it against the root

Re: [PATCH 00/11 V3] add show command to the subvol sub command

2013-01-21 Thread Anand Jain
Gene, I should do that in couple of days. Thanks. Anand On 01/21/2013 08:19 AM, Gene Czarcinski wrote: On 01/10/2013 06:41 AM, Anand Jain wrote: This is an attempt to make btrfs cli more end user friendly. And adds show subcommand to display all known (as of now) information of the given

[PATCH 02/10] Btrfs-progs: move printing subvol list outside of btrfs_list_subvols

2013-01-23 Thread Anand Jain
To improve the code reuse its better to have btrfs_list_subvols just return list of subvols witout printing Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h | 2 +- cmds-subvolume.c | 4 ++-- 3 files changed, 21 insertions

[PATCH 03/10] Btrfs-progs: add parent uuid for snapshots

2013-01-23 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 32 +++- btrfs-list.h | 1 + cmds-subvolume.c | 6 +- 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b656286..cc065e9 100644 --- a/btrfs

[PATCH 08/10] Btrfs-progs: make printing subvol extensible to newer layouts

2013-01-23 Thread Anand Jain
Currently you can print subvol in a list or table format. This patch will provide a way to extend this to other formats like the upcoming raw format. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 26 +++--- btrfs-list.h | 3 +++ cmds-subvolume.c

[PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-23 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile | 4 ++-- btrfsctl.c | 7 --- cmds-balance.c | 1 + cmds-inspect.c | 1 + cmds-qgroup.c| 1

[PATCH 05/10] Btrfs-progs: add function btrfs_get_subvol to get root_info of a subvol

2013-01-23 Thread Anand Jain
We need a function which can get the root_info of a given subvol. This is in preparation to add support for the show sub-cli. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 38 ++ btrfs-list.h | 1 + 2 files changed, 39 insertions(+) diff

[PATCH 10/10] Btrfs-progs: add show subcommand to subvol cli

2013-01-23 Thread Anand Jain
This adds show sub-command to the btrfs subvol cli to display detailed inforamtion of the given subvol or snapshot. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 25 +++- btrfs-list.h | 3 +- cmds-subvolume.c | 176

[PATCH 09/10] Btrfs-progs: make get_subvol_name non cmds-send specific

2013-01-23 Thread Anand Jain
get_subvol_name can be used other than the just with in cmds-send.c so this patch will make it possible with out changing the original intentions. Signed-off-by: Anand Jain anand.j...@oracle.com --- cmds-send.c | 12 ++-- commands.h | 1 + 2 files changed, 7 insertions(+), 6 deletions

[PATCH 07/10] Btrfs-progs: put find_mount_root() in commands.h

2013-01-23 Thread Anand Jain
A useful function need to define it in a header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup

[PATCH 06/10] Btrfs-progs: add method to filter snapshots by parent uuid

2013-01-23 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 6 ++ btrfs-list.h | 1 + 2 files changed, 7 insertions(+) diff --git a/btrfs-list.c b/btrfs-list.c index ec64a36..f5958cf 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1144,6 +1144,11 @@ static int filter_topid_equal

[PATCH 04/10] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-23 Thread Anand Jain
As we would add more ways to list and manage the subvols and snapshots, its better if we have struct root_info defined in the header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47

Re: [PATCH 00/11 V3] add show command to the subvol sub command

2013-01-23 Thread Anand Jain
for btrfs subvol cli Date: Wed, 23 Jan 2013 16:12:41 +0800 Thanks, Anand On 01/10/2013 07:41 PM, Anand Jain wrote: This is an attempt to make btrfs cli more end user friendly. And adds show subcommand to display all known (as of now) information of the given subvol including its snapshot(s

Re: [PATCH 00/10] add show sub-command for btrfs subvol cli

2013-01-23 Thread Anand Jain
However, you may want to wait a bit as David has a few more patches he is working on. Also, one of the new (not in for-chris) patches has a conflict with another patch in the first set. Pls let me know when David's repo is ready for the rebase so that I can resolve conflicts with this

[PATCH] Btrfs-progs: we need to have the string null terminated

2013-01-24 Thread Anand Jain
4.snap appended, similar to the names of the snapshots I made 22 hours ago. Signed-off-by: Anand Jain anand.j...@oracle.com Reported-by: Brendan Hide bren...@swiftspirit.co.za --- btrfs-list.c | 1 + 1 file changed, 1 insertion(+) diff --git a/btrfs-list.c b/btrfs-list.c index

Re: inconsistent output on sub list

2013-01-24 Thread Anand Jain
Brendan, --- [root@watricky mnt]# btrfs subvolume list / -a ID 258 gen 4226 top level 384 path media/smbshare :: [root@watricky mnt]# btrfs subvolume list /home -a ID 258 gen 4226 top level 5 path FS_TREE/__active/media/smbshare4.snap --- This is definitely a bug. Thanks

Re: [PATCH] Btrfs-progs: Fix minor problems with btrfslabel.c

2013-01-24 Thread Anand Jain
Thanks. comments below. On 01/24/2013 11:52 PM, Gene Czarcinski wrote: Fixed indentation, replace spaces with tabs. Signed-off-by: Danny Kukawka danny.kuka...@bisect.de Rebased, also fixed compiler warnings Signed-off-by: Gene Czarcinski g...@czarc.net --- btrfslabel.c | 57

[PATCH 02/10] Btrfs-progs: move printing subvol list outside of btrfs_list_subvols

2013-01-25 Thread Anand Jain
To improve the code reuse its better to have btrfs_list_subvols just return list of subvols witout printing Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h | 2 +- cmds-subvolume.c | 4 ++-- 3 files changed, 21 insertions

[PATCH 00/10 V2] add show sub-command for btrfs subvol cli

2013-01-25 Thread Anand Jain
Here is the V2 of this patch-set, kindly review and accept. v1-v2: . 2nd attempt to Rebase to git://repo.or.cz/btrfs-progs-unstable/devel.git for-chris and . Accepts Eric's review comments. Thanks Anand Jain (10): Btrfs-progs: move open_file_or_dir() to utils.c Btrfs-progs: move

[PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-25 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile | 4 ++-- btrfsctl.c | 7 --- cmds-balance.c | 1 + cmds-inspect.c | 1 + cmds-qgroup.c| 1

[PATCH 03/10] Btrfs-progs: add parent uuid for snapshots

2013-01-25 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 34 -- btrfs-list.h | 1 + cmds-subvolume.c | 6 +- 3 files changed, 34 insertions(+), 7 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b404e1d..13a365d 100644

[PATCH 05/10] Btrfs-progs: add function btrfs_get_subvol to get root_info of a subvol

2013-01-25 Thread Anand Jain
We need a function which can get the root_info of a given subvol. This is in preparation to add support for the show sub-cli. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 38 ++ btrfs-list.h | 1 + 2 files changed, 39 insertions(+) diff

[PATCH 07/10] Btrfs-progs: put find_mount_root() in commands.h

2013-01-25 Thread Anand Jain
A useful function need to define it in a header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup

[PATCH 08/10] Btrfs-progs: make printing subvol extensible to newer layouts

2013-01-25 Thread Anand Jain
Currently you can print subvol in a list or table format. This patch will provide a way to extend this to other formats like the upcoming raw format. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 26 +++--- btrfs-list.h | 3 +++ cmds-subvolume.c

[PATCH 06/10] Btrfs-progs: add method to filter snapshots by parent uuid

2013-01-25 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 6 ++ btrfs-list.h | 1 + 2 files changed, 7 insertions(+) diff --git a/btrfs-list.c b/btrfs-list.c index 0ee13b6..9c84ecb 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1142,6 +1142,11 @@ static int filter_topid_equal

[PATCH 04/10] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-25 Thread Anand Jain
As we would add more ways to list and manage the subvols and snapshots, its better if we have struct root_info defined in the header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47

[PATCH 09/10] Btrfs-progs: make get_subvol_name non cmds-send specific

2013-01-25 Thread Anand Jain
get_subvol_name can be used other than the just with in cmds-send.c so this patch will make it possible with out changing the original intentions. Signed-off-by: Anand Jain anand.j...@oracle.com --- cmds-send.c | 12 ++-- commands.h | 1 + 2 files changed, 7 insertions(+), 6 deletions

Re: [PATCH 05/10] Btrfs-progs: add function btrfs_get_subvol to get root_info of a subvol

2013-01-25 Thread Anand Jain
On 01/24/2013 12:49 PM, Eric Sandeen wrote: On 1/23/13 2:12 AM, Anand Jain wrote: We need a function which can get the root_info of a given subvol. This is in preparation to add support for the show sub-cli. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 38

[PATCH 10/10] Btrfs-progs: add show subcommand to subvol cli

2013-01-25 Thread Anand Jain
This adds show sub-command to the btrfs subvol cli to display detailed inforamtion of the given subvol or snapshot. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 25 +++- btrfs-list.h | 3 +- cmds-subvolume.c | 172

Re: [PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-25 Thread Anand Jain
Cool, I had this on my stack too. But can you maybe remove the nonsensical return values, and instead of renaming keeping the btrfsctl.c copy, why not just use a common copy in utils.c? It'd just be 2 checks for fd 0 in the btrfsctl callers. Thanks for the comments Eric. Though I agree,

Re: [PATCH 00/10] add show sub-command for btrfs subvol cli

2013-01-25 Thread Anand Jain
OK, in spite of saying that these patches did not apply clean, it was not terribly difficult to refit what did not apply. I did this in two steps: 1. I created the equivalent of the for-chris branch. This did not apply clean which surprised me. Yes I see it. Not sure where I went wrong,

Re: [PATCH 10/10] Btrfs-progs: add show subcommand to subvol cli

2013-01-25 Thread Anand Jain
Eric. All accepted. Thanks for the review. Anand On 01/24/2013 01:06 PM, Eric Sandeen wrote: On 1/23/13 2:12 AM, Anand Jain wrote: This adds show sub-command to the btrfs subvol cli to display detailed inforamtion of the given subvol or snapshot. Couple things below. Signed-off

[PATCH 03/10] Btrfs-progs: add parent uuid for snapshots

2013-01-25 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 34 -- btrfs-list.h | 1 + cmds-subvolume.c | 6 +- 3 files changed, 34 insertions(+), 7 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b404e1d..13a365d 100644

[RESEND] [PATCH 00/10 V2] add show sub-command for btrfs subvol cli

2013-01-25 Thread Anand Jain
Here is the V2 of this patch-set, kindly review and accept. v1-v2: . 2nd attempt to Rebase to git://repo.or.cz/btrfs-progs-unstable/devel.git for-chris and . Accepts Eric's review comments. Thanks Anand Jain (10): Btrfs-progs: move open_file_or_dir() to utils.c Btrfs-progs: move

[PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-25 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile | 4 ++-- btrfsctl.c | 7 --- cmds-balance.c | 1 + cmds-inspect.c | 1 + cmds-qgroup.c| 1

[PATCH 02/10] Btrfs-progs: move printing subvol list outside of btrfs_list_subvols

2013-01-25 Thread Anand Jain
To improve the code reuse its better to have btrfs_list_subvols just return list of subvols witout printing Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h | 2 +- cmds-subvolume.c | 4 ++-- 3 files changed, 21 insertions

[PATCH 04/10] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-25 Thread Anand Jain
As we would add more ways to list and manage the subvols and snapshots, its better if we have struct root_info defined in the header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47

[PATCH 05/10] Btrfs-progs: add function btrfs_get_subvol to get root_info of a subvol

2013-01-25 Thread Anand Jain
We need a function which can get the root_info of a given subvol. This is in preparation to add support for the show sub-cli. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 38 ++ btrfs-list.h | 1 + 2 files changed, 39 insertions(+) diff

[PATCH 06/10] Btrfs-progs: add method to filter snapshots by parent uuid

2013-01-25 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 6 ++ btrfs-list.h | 1 + 2 files changed, 7 insertions(+) diff --git a/btrfs-list.c b/btrfs-list.c index 0ee13b6..9c84ecb 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1142,6 +1142,11 @@ static int filter_topid_equal

[PATCH 07/10] Btrfs-progs: put find_mount_root() in commands.h

2013-01-25 Thread Anand Jain
A useful function need to define it in a header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup

[PATCH 08/10] Btrfs-progs: make printing subvol extensible to newer layouts

2013-01-25 Thread Anand Jain
Currently you can print subvol in a list or table format. This patch will provide a way to extend this to other formats like the upcoming raw format. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 26 +++--- btrfs-list.h | 3 +++ cmds-subvolume.c

[PATCH 10/10] Btrfs-progs: add show subcommand to subvol cli

2013-01-25 Thread Anand Jain
This adds show sub-command to the btrfs subvol cli to display detailed inforamtion of the given subvol or snapshot. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 25 +++- btrfs-list.h | 3 +- cmds-subvolume.c | 172

[PATCH 09/10] Btrfs-progs: make get_subvol_name non cmds-send specific

2013-01-25 Thread Anand Jain
get_subvol_name can be used other than the just with in cmds-send.c so this patch will make it possible with out changing the original intentions. Signed-off-by: Anand Jain anand.j...@oracle.com --- cmds-send.c | 12 ++-- commands.h | 1 + 2 files changed, 7 insertions(+), 6 deletions

Re: [PATCH] Btrfs-progs: v2 Fix minor problems in btrfslabel.c

2013-01-27 Thread Anand Jain
On 01/27/2013 02:09 AM, Gene Czarcinski wrote: Fixed indentation, replace spaces with tabs. Signed-off-by: Danny Kukawka danny.kuka...@bisect.de Rebased; fixed compiler warnings; added space after if Signed-off-by: Gene Czarcinski g...@czarc.net Reviewed-by: Anand Jain anand.j...@oracle.com

Re: [PATCH] Btrfs-progs: remove btrfsctl, btrfs-show and btrfs-vol from default build

2013-01-27 Thread Anand Jain
This patch is much needed. thanks. Further, IMO the summary may provide a table of mapping of the original to its predecessor command-and-option so that - it will ensure we have taken care of all the original features in the new cli, and it will help to document for the onlooker. eg:

Re: [PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-27 Thread Anand Jain
Good to have the old src-code removed as well. yum snapshot plugin is out of btrfsctl. http://lists.baseurl.org/pipermail/yum-devel/2012-July/009396.html Thanks, Anand -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to

[PATCH 00/10 v3] add show sub-command for btrfs subvol cli

2013-01-27 Thread Anand Jain
Here is the v3 of this patch-set, kindly review and accept. v2-v3: . Accepts review comments from Eric. Anand Jain (10): Btrfs-progs: move open_file_or_dir() to utils.c Btrfs-progs: move printing subvol list outside of btrfs_list_subvols Btrfs-progs: add parent uuid for snapshots Btrfs

[PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-27 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile | 4 ++-- btrfsctl.c | 7 --- cmds-balance.c | 1 + cmds-inspect.c | 1 + cmds-qgroup.c| 1

[PATCH 02/10] Btrfs-progs: move printing subvol list outside of btrfs_list_subvols

2013-01-27 Thread Anand Jain
To improve the code reuse its better to have btrfs_list_subvols just return list of subvols witout printing Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h | 2 +- cmds-subvolume.c | 4 ++-- 3 files changed, 21 insertions

[PATCH 03/10] Btrfs-progs: add parent uuid for snapshots

2013-01-27 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 34 -- btrfs-list.h | 1 + cmds-subvolume.c | 6 +- 3 files changed, 34 insertions(+), 7 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b404e1d..13a365d 100644

[PATCH 04/10] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-27 Thread Anand Jain
As we would add more ways to list and manage the subvols and snapshots, its better if we have struct root_info defined in the header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47

[PATCH 05/10] Btrfs-progs: add function btrfs_get_subvol to get root_info of a subvol

2013-01-27 Thread Anand Jain
We need a function which can get the root_info of a given subvol. This is in preparation to add support for the show sub-cli. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 38 ++ btrfs-list.h | 1 + 2 files changed, 39 insertions(+) diff

[PATCH 06/10] Btrfs-progs: add method to filter snapshots by parent uuid

2013-01-27 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 6 ++ btrfs-list.h | 1 + 2 files changed, 7 insertions(+) diff --git a/btrfs-list.c b/btrfs-list.c index 0ee13b6..9c84ecb 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1142,6 +1142,11 @@ static int filter_topid_equal

[PATCH 07/10] Btrfs-progs: put find_mount_root() in commands.h

2013-01-27 Thread Anand Jain
A useful function need to define it in a header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup

[PATCH 09/10] Btrfs-progs: make get_subvol_name non cmds-send specific

2013-01-27 Thread Anand Jain
get_subvol_name can be used other than the just with in cmds-send.c so this patch will make it possible with out changing the original intentions. Signed-off-by: Anand Jain anand.j...@oracle.com --- cmds-send.c | 12 ++-- commands.h | 1 + 2 files changed, 7 insertions(+), 6 deletions

[PATCH 10/10] Btrfs-progs: add show subcommand to subvol cli

2013-01-27 Thread Anand Jain
This adds show sub-command to the btrfs subvol cli to display detailed inforamtion of the given subvol or snapshot. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 25 +++-- btrfs-list.h | 3 +- cmds-subvolume.c | 155

[PATCH 08/10] Btrfs-progs: make printing subvol extensible to newer layouts

2013-01-27 Thread Anand Jain
Currently you can print subvol in a list or table format. This patch will provide a way to extend this to other formats like the upcoming raw format. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 26 +++--- btrfs-list.h | 3 +++ cmds-subvolume.c

[RESEND] [PATCH 00/10 v3] add show sub-command for btrfs subvol cli

2013-01-27 Thread Anand Jain
(resent, fixed git in-reply-to and v2-v3: change log sorry about that). Here is the v3 of this patch-set, kindly review and accept. v2-v3: . Accepts review comments from Stefan Anand Jain (10): Btrfs-progs: move open_file_or_dir() to utils.c Btrfs-progs: move printing subvol list

[PATCH 02/10] Btrfs-progs: move printing subvol list outside of btrfs_list_subvols

2013-01-27 Thread Anand Jain
To improve the code reuse its better to have btrfs_list_subvols just return list of subvols witout printing Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 28 ++-- btrfs-list.h | 2 +- cmds-subvolume.c | 4 ++-- 3 files changed, 21 insertions

[PATCH 01/10] Btrfs-progs: move open_file_or_dir() to utils.c

2013-01-27 Thread Anand Jain
), the required XOPEN version was raised from 6 to 7. Signed-off-by: Anand Jain anand.j...@oracle.com Original-Signed-off-by: Stefan Behrens sbehr...@giantdisaster.de --- Makefile | 4 ++-- btrfsctl.c | 7 --- cmds-balance.c | 1 + cmds-inspect.c | 1 + cmds-qgroup.c| 1

[PATCH 04/10] Btrfs-progs: move struct root_info to btrfs-list.h

2013-01-27 Thread Anand Jain
As we would add more ways to list and manage the subvols and snapshots, its better if we have struct root_info defined in the header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 47 --- btrfs-list.h | 47

[PATCH 03/10] Btrfs-progs: add parent uuid for snapshots

2013-01-27 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 34 -- btrfs-list.h | 1 + cmds-subvolume.c | 6 +- 3 files changed, 34 insertions(+), 7 deletions(-) diff --git a/btrfs-list.c b/btrfs-list.c index b404e1d..13a365d 100644

[PATCH 06/10] Btrfs-progs: add method to filter snapshots by parent uuid

2013-01-27 Thread Anand Jain
Signed-off-by: Anand Jain anand.j...@oracle.com --- btrfs-list.c | 6 ++ btrfs-list.h | 1 + 2 files changed, 7 insertions(+) diff --git a/btrfs-list.c b/btrfs-list.c index 0ee13b6..9c84ecb 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -1142,6 +1142,11 @@ static int filter_topid_equal

[PATCH 07/10] Btrfs-progs: put find_mount_root() in commands.h

2013-01-27 Thread Anand Jain
A useful function need to define it in a header file. Signed-off-by: Anand Jain anand.j...@oracle.com --- commands.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands.h b/commands.h index 8114a73..9b77f3e 100644 --- a/commands.h +++ b/commands.h @@ -103,3 +103,6 @@ int cmd_qgroup

<    2   3   4   5   6   7   8   9   10   11   >