search for: root_lookup

Displaying 11 results from an estimated 11 matches for "root_lookup".

2012 Aug 01
17
[PATCH] add crtime to the snapshot list
From: Anand <anand.jain@oracle.com> This patch adds creation-time to the snapshot list display, which would help user to better manage the snapshots when number of snapshots grow substantially. This patch is developed and on top of the send/receive btrfs and btrfs-progs repo at git://github.com/ablock84/linux-btrfs.git (send-v2) git://github.com/ablock84/btrfs-progs.git (send-v2)
2011 Jul 07
5
[PATCH v1 0/2] Btrfs-progs: commands "resolve inode" and "resolve logical"
The kernel patch series just sent (Subject: "Btrfs: scrub: print path to corrupted files and trigger nodatasum fixup") introduces two new ioctls to do in-kernel filesystem path construction. This series provides the corresponding userspace changes, adding two new commands to the btrfs utility: -- btrfs resolve inode [-v] <inode> <path> resolves an <inode> to all
2013 Apr 11
0
[PATCH] Btrfs-progs: enhance 'btrfs subvolume list'
...= 0; i < BTRFS_LIST_MAX; i++) + if (strcmp(field_name, all_field_items[i]) == 0) + return i; + return -1; +} + struct btrfs_list_comparer_set *btrfs_list_alloc_comparer_set(void) { struct btrfs_list_comparer_set *set; @@ -391,52 +490,70 @@ static struct root_info *root_tree_search(struct root_lookup *root_tree, return NULL; } -static int update_root(struct root_lookup *root_lookup, - u64 root_id, u64 ref_tree, u64 root_offset, u64 flags, - u64 dir_id, char *name, int name_len, u64 ogen, u64 gen, - time_t ot, void *uuid, void *puuid) +static int set_root_info(struct...
2012 Jun 29
12
[PATCH 1/3] Btrfs-progs: add support to set subvolume/snapshot readonly
Setting subvolume/snapshot readonly has been missing for a long time. With this patch, we can set a subvolume/snapshot readonly via: o btrfs subvolume set-ro <path> Signed-off-by: Liu Bo <liubo2009@cn.fujitsu.com> --- cmds-subvolume.c | 40 ++++++++++++++++++++++++++++++++++++++++ ioctl.h | 7 +++++++ 2 files changed, 47 insertions(+), 0 deletions(-) diff --git
2013 Nov 16
16
[PATCH] BTRFS-PROG: recursively subvolume snapshot and delete
Hi All, the following patches implement the recursively snapshotting and deleting of a subvolume. To snapshot recursively you must pass the -R switch: # btrfs subvolume create sub1 Create subvolume ''./sub1'' # btrfs subvolume create sub1/sub2 Create subvolume ''sub1/sub2'' # btrfs subvolume snapshot -R sub1 sub1-snap Create a snapshot of
2011 Jul 12
0
[PATCH]: Use a general way to get the default subvolume for btrfs
...off += sizeof(*sh); + if (sh->type == BTRFS_DIR_ITEM_KEY) { + dir_item = (struct btrfs_dir_item *)(args.buf + off); + name_len = dir_item->name_len; + name = (char *)(dir_item + 1); + + + /*add_root(&root_lookup, sh->objectid, sh->offset, + dir_id, name, name_len);*/ + strncpy(dirname, name, name_len); + dirname[name_len] = '\0'; + if (strcmp(dirname, "default") == 0) { + defaultsubvolid = dir_item-&g...
2013 Oct 23
0
[PATCH] btrfs-progs: add filter for deleted but uncleanded subvolumes
...(set->only_deleted && !ri->deleted) + return 0; + + if (!set->only_deleted && ri->deleted) + return 0; + for (i = 0; i < set->nfilters; i++) { if (!set->filters[i].filter_func) break; @@ -1281,12 +1298,13 @@ static void __filter_and_sort_subvol(struct root_lookup *all_subvols, entry = rb_entry(n, struct root_info, rb_node); ret = resolve_root(all_subvols, entry, top_id); - if (ret == -ENOENT) - goto skip; + if (ret == -ENOENT) { + entry->full_path = strdup("DELETED"); + entry->deleted = 1; + } ret = filter_root(entry, fil...
2011 Apr 07
0
[PATCH] btrfs-progs: cast u64 to long long to avoid printf warnings
...xpects type ‘long long unsigned int’, but argument 4 has type ‘u64’ Fix them. Signed-off-by: Anton Blanchard <anton@samba.org> --- diff --git a/btrfs-list.c b/btrfs-list.c index 93766a8..c602b87 100644 --- a/btrfs-list.c +++ b/btrfs-list.c @@ -249,7 +249,8 @@ static int resolve_root(struct root_lookup *rl, struct root_info *ri) break; } } - printf("ID %llu top level %llu path %s\n", ri->root_id, top_id, + printf("ID %llu top level %llu path %s\n", + (unsigned long long)ri->root_id, (unsigned long long)top_id, full_path); free(full_path); ret...
2010 Jun 05
0
PULL: Properly cast and avoid compiler warnings, fixes build on alpha and ia64.
...der Kurtz <kurtz.alex@googlemail.com>, and Daniel Baumann <daniel@debian.org> (see Debian Bugs #539433 and #583768). diff --git a/btrfs-list.c b/btrfs-list.c index 7741705..c2c5712 100644 - --- a/btrfs-list.c +++ b/btrfs-list.c @@ -248,8 +248,9 @@ static int resolve_root(struct root_lookup *rl, struct root_info *ri) break; } } - - printf("ID %llu top level %llu path %s\n", ri->root_id, top_id, - - full_path); + printf("ID %llu top level %llu path %s\n", + (long long unsigned...
2012 Feb 29
15
[RFC] [PATCH] Add btrfs autosnap feature
From: anand jain <anand.jain@oracle.com> Anand Jain (1): [RFC] Add btrfs autosnap feature Makefile | 6 +- autosnap.c | 1553 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ autosnap.h | 81 +++ btrfs-list.c | 140 +++++- btrfs.c | 46 ++- btrfs_cmds.c | 186 +++++++- btrfs_cmds.h | 3 +- scrub.c | 1 + 8 files changed, 1982 insertions(+), 34
2013 Apr 09
19
[PATCH 00/17] Btrfs-progs: some receive related patches
Most fixes are trivial. The one from Alex is fixing a real bug that several users have reported. Alex sent the patch half a year ago and it was not yet integrated. The patch "Use /proc/mounts instead of /etc/mtab" is a repost. The patch "btrfs-receive optionally honors the end-cmd" is a preparation step to allow backup tools to multiplex a single communication stream (e.g. a