[RFC,v2,0/4] undelete subvolume online version
mbox series

Message ID 20180911112903.25985-1-lufq.fnst@cn.fujitsu.com
Headers show
Series
  • undelete subvolume online version
Related show

Message

Lu Fengqi Sept. 11, 2018, 11:28 a.m. UTC
This patchset will add the BTRFS_IOC_SUBVOL_UNDELETE ioctl for online
btrfs subvolume undelete.

And using the online_undelete version of btrfs-progs, user can recover
the subvolume given by <subvol_id> to the directory given by <dest>. The
optional parameter [-n <name>] can be used to set the name of the
recovered subvolume.

# btrfs subvolume undelete [-n <name>] <subvol_id> <dest>

btrfs online undelete version:
https://github.com/littleroad/linux.git undelete

btrfs-progs online undelete version:
https://github.com/littleroad/btrfs-progs.git online_undelete

Issue: #82

Lu Fengqi (4):
  btrfs: factor out btrfs_link_subvol from create_subvol
  btrfs: don't BUG_ON() in btrfs_link_subvol()
  btrfs: undelete: introduce btrfs_undelete_subvolume
  btrfs: undelete: Add BTRFS_IOCTL_SUBVOL_UNDELETE ioctl

 fs/btrfs/ioctl.c           | 247 +++++++++++++++++++++++++++++++++----
 include/uapi/linux/btrfs.h |   7 ++
 2 files changed, 231 insertions(+), 23 deletions(-)