2010-03-11 21:32:50 +00:00
|
|
|
.TH BTRFS 8 "" "btrfs" "btrfs"
|
|
|
|
.\"
|
|
|
|
.\" Man page written by Goffredo Baroncelli <kreijack@inwind.it> (Feb 2010)
|
2013-07-23 02:43:22 +00:00
|
|
|
.\" Modified by Qu Wenruo <quwenruo@cn.fujitsu.com> (Jun 2013)
|
2010-03-11 21:32:50 +00:00
|
|
|
.\"
|
|
|
|
.SH NAME
|
|
|
|
btrfs \- control a btrfs filesystem
|
|
|
|
.SH SYNOPSIS
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume create\fP [-i \fI<qgroupid>\fP] [\fI<dest>\fP/]\fI<name>\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-12-12 18:11:26 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume delete\fP [\fIoptions\fP] \fI<subvolume>\fP [\fI<subvolume>...\fP]
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume list\fP [\fIoptions\fP] [-G [+|-]\fIvalue\fP] [-C [+|-]\fIvalue\fP] [--sort=rootid,gen,ogen,path] \fI<path>\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume snapshot\fP [-r] \fI<source>\fP \fI<dest>\fP|[\fI<dest>\fP/]\fI<name>\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2011-07-12 02:48:37 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume get-default\fP\fI <path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume set-default\fP\fI <id> <path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBsubvolume find-new\fP\fI <subvolume> <lastgen>\fP
|
2013-01-31 05:35:31 +00:00
|
|
|
.PP
|
2013-02-01 07:56:28 +00:00
|
|
|
\fBbtrfs\fP \fBsubvolume show\fP\fI <path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBfilesystem df\fP\fI <path>\fP
|
|
|
|
.PP
|
2013-10-08 03:41:38 +00:00
|
|
|
\fBbtrfs\fP \fBfilesystem show\fP [\fI--mounted\fP|\fI--all-devices\fP|\fI<uuid>\fP]\fP
|
2011-12-16 08:46:48 +00:00
|
|
|
.PP
|
2010-03-11 21:32:50 +00:00
|
|
|
\fBbtrfs\fP \fBfilesystem sync\fP\fI <path> \fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBfilesystem defragment\fP [\fIoptions\fP] \fI<file>\fP|\fI<dir>\fP [\fI<file>\fP|\fI<dir>...\fP]\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBfilesystem resize\fP [\fIdevid\fP:][+/\-]\fI<size>\fP[gkm]|[\fIdevid\fP:]\fImax <path>\fP
|
2010-12-05 17:46:44 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBfilesystem label\fP [\fI<device>\fP|\fI<mount_point>\fP] [\fI<newlabel>\fP]
|
2013-05-13 15:23:39 +00:00
|
|
|
.PP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fB[filesystem] balance start\fP [\fIoptions\fP] \fI<path>\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fB[filesystem] balance pause\fP\fI <path>\fP
|
2012-05-15 09:30:39 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fB[filesystem] balance cancel\fP\fI <path>\fP
|
Update/clean up btrfs help and man page V2
Hi all,
enclose you can find a patch which improves the help of the btrfs commands,
updates the INSTALL file and the btrfs (command) man page.
Regarding the help of the btrfs command:
- moved the "subvolume set-default" command in the "subvolume" commands group
- removed a wrong new line
- small tweak on the basis of Andreas suggestion
Regarding the btrfs command man page:
- renaming the command "device balance" in "filesystem balance" (thanks to
Andreas Phillipp to highlight that)
- adding the entry "subvolume find-new"
- document the switches of the command "filesystem defrag"
- document the <devid> facility of the command "filesystem resize"
- small tweak on the basis of Andreas suggestion
Regarding the INSTALL file, which was very old, I removed the reference of the
old btrfsctl utility and changed the examples using the btrfs command.
I removed the old (and now wrong) statement about the inability to delete a
subvolume/snapshot
Chris, you can pull the patch from the branch "help_cleanup" of the following
repository.
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git
(or you can browse the changes at
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git/?p=btrfs-
progs-unstable-all.git;a=summary)
The patch is very simple: only updates the man page, the INSTALL file and
moves/updates some lines in the help of btrfs command. Comments are welcome.
Regards
G.Baroncelli
INSTALL | 29 ++++++++++++++++++++---------
btrfs.c | 24 ++++++++++++------------
man/btrfs.8.in | 45 +++++++++++++++++++++++++--------------------
3 files changed, 57 insertions(+), 41 deletions(-)
all the block devices.
.TP
@@ -138,21 +143,21 @@ can expand the partition before enlarging the filesystem
and shrink the
partition after reducing the size of the filesystem.
.TP
-\fBfilesystem show\fR [<uuid>|<label>]\fR
-Show the btrfs filesystem with some additional info. If no UUID or label is
-passed, \fBbtrfs\fR show info of all the btrfs filesystem.
+\fBfilesystem show\fR [<device>|<uuid>|<label>]\fR
+Show the btrfs filesystem with some additional info. If no argument is
+passed, \fBbtrfs\fR shows info of all the btrfs filesystems.
.TP
-\fBdevice balance\fR \fI<path>\fR
+\fBfilesystem balance\fR \fI<path>\fR
Balance the chunks of the filesystem identified by \fI<path>\fR
across the devices.
.TP
-\fBdevice add\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice add\fR\fI <device> [<device>...] <path>\fR
Add device(s) to the filesystem identified by \fI<path>\fR.
.TP
-\fBdevice delete\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice delete\fR\fI <device> [<device>...] <path>\fR
Remove device(s) from a filesystem identified by \fI<path>\fR.
.PP
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2010-12-05 17:47:45 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fB[filesystem] balance resume\fP\fI <path>\fP
|
2011-07-18 12:37:25 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fB[filesystem] balance status\fP [-v] \fI<path>\fP
|
2012-05-07 12:00:20 +00:00
|
|
|
.PP
|
|
|
|
.PP
|
2013-09-27 17:30:05 +00:00
|
|
|
\fBbtrfs\fP \fBdevice add\fP [-Kf] \fI<device>\fP [\fI<device>...\fP] \fI<path>\fP
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBdevice delete\fP \fI<device>\fP [\fI<device>...\fP] \fI<path>\fP
|
|
|
|
.PP
|
2013-10-08 03:41:38 +00:00
|
|
|
\fBbtrfs\fP \fBdevice scan\fP [\fI--all-devices\fP|\fI<device> \P[\fI<device>...\fP]
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBdevice ready\fP\fI <device>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBdevice stats\fP [-z] {\fI<path>\fP|\fI<device>\fP}
|
|
|
|
.PP
|
2012-05-07 12:00:20 +00:00
|
|
|
.PP
|
2013-12-02 06:42:25 +00:00
|
|
|
\fBbtrfs\fP \fBscrub start\fP [-BdqrRf] [-c \fIioprio_class\fP -n \fIioprio_classdata\fP] {\fI<path>\fP|\fI<device>\fP}
|
2011-07-18 12:37:25 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBscrub cancel\fP {\fI<path>\fP|\fI<device>\fP}
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBscrub resume\fP [-BdqrR] [-c \fIioprio_class\fP -n \fIioprio_classdata\fP] {\fI<path>\fP|\fI<device>\fP}
|
2011-07-18 12:37:25 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBscrub status\fP [-d] {\fI<path>\fP|\fI<device>\fP}
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBcheck\fP [\fIoptions\fP] \fI<device>\fP
|
|
|
|
.PP
|
2013-09-17 15:21:21 +00:00
|
|
|
\fBbtrfs\fP \fBrescue chunk-recover\fP [\fIoptions\fP] \fI<path>\fP
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
2013-11-14 13:40:43 +00:00
|
|
|
\fBbtrfs\fP \fBrescue super-recover\fP [\fIoptions\fP] \fI<path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBrestore\fP [\fIoptions\fP] \fI<device>\fP
|
|
|
|
.PP
|
|
|
|
.PP
|
2011-07-08 10:25:11 +00:00
|
|
|
\fBbtrfs\fP \fBinspect-internal inode-resolve\fP [-v] \fI<inode>\fP \fI<path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBinspect-internal logical-resolve\fP [-Pv] [-s \fI<size>\fP] \fI<logical>\fP \fI<path>\fP
|
2011-07-08 10:25:11 +00:00
|
|
|
.PP
|
2013-04-23 10:18:55 +00:00
|
|
|
\fBbtrfs\fP \fBinspect-internal subvolid-resolve\fP \fI<subvolid>\fP \fI<path>\fP
|
|
|
|
.PP
|
2013-09-18 16:19:30 +00:00
|
|
|
\fBbtrfs\fP \fBinspect-internal rootid\fP \fI<path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
2013-12-16 15:47:10 +00:00
|
|
|
\fBbtrfs\fP \fBsend\fP [-ve] [-p \fI<parent>\fP] [-c \fI<clone-src>\fP] [-f \fI<outfile>\fP] \fI<subvol>\fP [\fI<subvol>\fP...]
|
2013-07-23 02:43:22 +00:00
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBreceive\fP [-ve] [-f \fI<infile>\fP] \fI<mount>\fP
|
|
|
|
.PP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBquota enable\fP\fI <path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBquota disable\fP\fI <path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBquota rescan\fP [-s] \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
.PP
|
2013-03-21 08:33:37 +00:00
|
|
|
\fBbtrfs\fP \fBqgroup assign\fP \fI<src>\fP \fI<dst>\fP \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBqgroup remove\fP \fI<src>\fP \fI<dst>\fP \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBqgroup create\fP \fI<qgroupid>\fP \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBqgroup destroy\fP \fI<qgroupid>\fP \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBqgroup show\fP \fI<path>\fP
|
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBqgroup limit\fP [\fIoptions\fP] \fI<size>\fP|\fBnone\fP [\fI<qgroupid>\fP] \fI<path>\fP
|
|
|
|
.PP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBreplace start\fP [-Bfr] \fI<srcdev>\fP|\fI<devid> <targetdev> <mount_point>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBreplace status\fP [-1] \fI<mount_point>\fP
|
2010-03-11 21:32:50 +00:00
|
|
|
.PP
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBbtrfs\fP \fBreplace cancel\fP \fI<mount_point>\fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fBhelp|\-\-help \fP
|
|
|
|
.PP
|
|
|
|
\fBbtrfs\fP \fB<command> \-\-help \fP
|
2011-01-23 15:31:07 +00:00
|
|
|
.PP
|
2010-03-11 21:32:50 +00:00
|
|
|
.SH DESCRIPTION
|
|
|
|
.B btrfs
|
|
|
|
is used to control the filesystem and the files and directories stored. It is
|
|
|
|
the tool to create or destroy a snapshot or a subvolume for the
|
|
|
|
filesystem, to defrag a file or a directory, flush the data to the disk,
|
|
|
|
to resize the filesystem, to scan the device.
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
It is possible to abbreviate the commands unless the commands are ambiguous.
|
2010-03-11 21:32:50 +00:00
|
|
|
For example: it is possible to run
|
|
|
|
.I btrfs sub snaps
|
|
|
|
instead of
|
|
|
|
.I btrfs subvolume snapshot.
|
|
|
|
But
|
Update/clean up btrfs help and man page V2
Hi all,
enclose you can find a patch which improves the help of the btrfs commands,
updates the INSTALL file and the btrfs (command) man page.
Regarding the help of the btrfs command:
- moved the "subvolume set-default" command in the "subvolume" commands group
- removed a wrong new line
- small tweak on the basis of Andreas suggestion
Regarding the btrfs command man page:
- renaming the command "device balance" in "filesystem balance" (thanks to
Andreas Phillipp to highlight that)
- adding the entry "subvolume find-new"
- document the switches of the command "filesystem defrag"
- document the <devid> facility of the command "filesystem resize"
- small tweak on the basis of Andreas suggestion
Regarding the INSTALL file, which was very old, I removed the reference of the
old btrfsctl utility and changed the examples using the btrfs command.
I removed the old (and now wrong) statement about the inability to delete a
subvolume/snapshot
Chris, you can pull the patch from the branch "help_cleanup" of the following
repository.
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git
(or you can browse the changes at
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git/?p=btrfs-
progs-unstable-all.git;a=summary)
The patch is very simple: only updates the man page, the INSTALL file and
moves/updates some lines in the help of btrfs command. Comments are welcome.
Regards
G.Baroncelli
INSTALL | 29 ++++++++++++++++++++---------
btrfs.c | 24 ++++++++++++------------
man/btrfs.8.in | 45 +++++++++++++++++++++++++--------------------
3 files changed, 57 insertions(+), 41 deletions(-)
all the block devices.
.TP
@@ -138,21 +143,21 @@ can expand the partition before enlarging the filesystem
and shrink the
partition after reducing the size of the filesystem.
.TP
-\fBfilesystem show\fR [<uuid>|<label>]\fR
-Show the btrfs filesystem with some additional info. If no UUID or label is
-passed, \fBbtrfs\fR show info of all the btrfs filesystem.
+\fBfilesystem show\fR [<device>|<uuid>|<label>]\fR
+Show the btrfs filesystem with some additional info. If no argument is
+passed, \fBbtrfs\fR shows info of all the btrfs filesystems.
.TP
-\fBdevice balance\fR \fI<path>\fR
+\fBfilesystem balance\fR \fI<path>\fR
Balance the chunks of the filesystem identified by \fI<path>\fR
across the devices.
.TP
-\fBdevice add\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice add\fR\fI <device> [<device>...] <path>\fR
Add device(s) to the filesystem identified by \fI<path>\fR.
.TP
-\fBdevice delete\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice delete\fR\fI <device> [<device>...] <path>\fR
Remove device(s) from a filesystem identified by \fI<path>\fR.
.PP
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2010-12-05 17:47:45 +00:00
|
|
|
.I btrfs file s
|
2010-03-11 21:32:50 +00:00
|
|
|
is not allowed, because
|
Update/clean up btrfs help and man page V2
Hi all,
enclose you can find a patch which improves the help of the btrfs commands,
updates the INSTALL file and the btrfs (command) man page.
Regarding the help of the btrfs command:
- moved the "subvolume set-default" command in the "subvolume" commands group
- removed a wrong new line
- small tweak on the basis of Andreas suggestion
Regarding the btrfs command man page:
- renaming the command "device balance" in "filesystem balance" (thanks to
Andreas Phillipp to highlight that)
- adding the entry "subvolume find-new"
- document the switches of the command "filesystem defrag"
- document the <devid> facility of the command "filesystem resize"
- small tweak on the basis of Andreas suggestion
Regarding the INSTALL file, which was very old, I removed the reference of the
old btrfsctl utility and changed the examples using the btrfs command.
I removed the old (and now wrong) statement about the inability to delete a
subvolume/snapshot
Chris, you can pull the patch from the branch "help_cleanup" of the following
repository.
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git
(or you can browse the changes at
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git/?p=btrfs-
progs-unstable-all.git;a=summary)
The patch is very simple: only updates the man page, the INSTALL file and
moves/updates some lines in the help of btrfs command. Comments are welcome.
Regards
G.Baroncelli
INSTALL | 29 ++++++++++++++++++++---------
btrfs.c | 24 ++++++++++++------------
man/btrfs.8.in | 45 +++++++++++++++++++++++++--------------------
3 files changed, 57 insertions(+), 41 deletions(-)
all the block devices.
.TP
@@ -138,21 +143,21 @@ can expand the partition before enlarging the filesystem
and shrink the
partition after reducing the size of the filesystem.
.TP
-\fBfilesystem show\fR [<uuid>|<label>]\fR
-Show the btrfs filesystem with some additional info. If no UUID or label is
-passed, \fBbtrfs\fR show info of all the btrfs filesystem.
+\fBfilesystem show\fR [<device>|<uuid>|<label>]\fR
+Show the btrfs filesystem with some additional info. If no argument is
+passed, \fBbtrfs\fR shows info of all the btrfs filesystems.
.TP
-\fBdevice balance\fR \fI<path>\fR
+\fBfilesystem balance\fR \fI<path>\fR
Balance the chunks of the filesystem identified by \fI<path>\fR
across the devices.
.TP
-\fBdevice add\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice add\fR\fI <device> [<device>...] <path>\fR
Add device(s) to the filesystem identified by \fI<path>\fR.
.TP
-\fBdevice delete\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice delete\fR\fI <device> [<device>...] <path>\fR
Remove device(s) from a filesystem identified by \fI<path>\fR.
.PP
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2010-12-05 17:47:45 +00:00
|
|
|
.I file s
|
2010-03-11 21:32:50 +00:00
|
|
|
may be interpreted both as
|
Update/clean up btrfs help and man page V2
Hi all,
enclose you can find a patch which improves the help of the btrfs commands,
updates the INSTALL file and the btrfs (command) man page.
Regarding the help of the btrfs command:
- moved the "subvolume set-default" command in the "subvolume" commands group
- removed a wrong new line
- small tweak on the basis of Andreas suggestion
Regarding the btrfs command man page:
- renaming the command "device balance" in "filesystem balance" (thanks to
Andreas Phillipp to highlight that)
- adding the entry "subvolume find-new"
- document the switches of the command "filesystem defrag"
- document the <devid> facility of the command "filesystem resize"
- small tweak on the basis of Andreas suggestion
Regarding the INSTALL file, which was very old, I removed the reference of the
old btrfsctl utility and changed the examples using the btrfs command.
I removed the old (and now wrong) statement about the inability to delete a
subvolume/snapshot
Chris, you can pull the patch from the branch "help_cleanup" of the following
repository.
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git
(or you can browse the changes at
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git/?p=btrfs-
progs-unstable-all.git;a=summary)
The patch is very simple: only updates the man page, the INSTALL file and
moves/updates some lines in the help of btrfs command. Comments are welcome.
Regards
G.Baroncelli
INSTALL | 29 ++++++++++++++++++++---------
btrfs.c | 24 ++++++++++++------------
man/btrfs.8.in | 45 +++++++++++++++++++++++++--------------------
3 files changed, 57 insertions(+), 41 deletions(-)
all the block devices.
.TP
@@ -138,21 +143,21 @@ can expand the partition before enlarging the filesystem
and shrink the
partition after reducing the size of the filesystem.
.TP
-\fBfilesystem show\fR [<uuid>|<label>]\fR
-Show the btrfs filesystem with some additional info. If no UUID or label is
-passed, \fBbtrfs\fR show info of all the btrfs filesystem.
+\fBfilesystem show\fR [<device>|<uuid>|<label>]\fR
+Show the btrfs filesystem with some additional info. If no argument is
+passed, \fBbtrfs\fR shows info of all the btrfs filesystems.
.TP
-\fBdevice balance\fR \fI<path>\fR
+\fBfilesystem balance\fR \fI<path>\fR
Balance the chunks of the filesystem identified by \fI<path>\fR
across the devices.
.TP
-\fBdevice add\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice add\fR\fI <device> [<device>...] <path>\fR
Add device(s) to the filesystem identified by \fI<path>\fR.
.TP
-\fBdevice delete\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice delete\fR\fI <device> [<device>...] <path>\fR
Remove device(s) from a filesystem identified by \fI<path>\fR.
.PP
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2010-12-05 17:47:45 +00:00
|
|
|
.I filesystem show
|
2010-03-11 21:32:50 +00:00
|
|
|
and as
|
Update/clean up btrfs help and man page V2
Hi all,
enclose you can find a patch which improves the help of the btrfs commands,
updates the INSTALL file and the btrfs (command) man page.
Regarding the help of the btrfs command:
- moved the "subvolume set-default" command in the "subvolume" commands group
- removed a wrong new line
- small tweak on the basis of Andreas suggestion
Regarding the btrfs command man page:
- renaming the command "device balance" in "filesystem balance" (thanks to
Andreas Phillipp to highlight that)
- adding the entry "subvolume find-new"
- document the switches of the command "filesystem defrag"
- document the <devid> facility of the command "filesystem resize"
- small tweak on the basis of Andreas suggestion
Regarding the INSTALL file, which was very old, I removed the reference of the
old btrfsctl utility and changed the examples using the btrfs command.
I removed the old (and now wrong) statement about the inability to delete a
subvolume/snapshot
Chris, you can pull the patch from the branch "help_cleanup" of the following
repository.
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git
(or you can browse the changes at
http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git/?p=btrfs-
progs-unstable-all.git;a=summary)
The patch is very simple: only updates the man page, the INSTALL file and
moves/updates some lines in the help of btrfs command. Comments are welcome.
Regards
G.Baroncelli
INSTALL | 29 ++++++++++++++++++++---------
btrfs.c | 24 ++++++++++++------------
man/btrfs.8.in | 45 +++++++++++++++++++++++++--------------------
3 files changed, 57 insertions(+), 41 deletions(-)
all the block devices.
.TP
@@ -138,21 +143,21 @@ can expand the partition before enlarging the filesystem
and shrink the
partition after reducing the size of the filesystem.
.TP
-\fBfilesystem show\fR [<uuid>|<label>]\fR
-Show the btrfs filesystem with some additional info. If no UUID or label is
-passed, \fBbtrfs\fR show info of all the btrfs filesystem.
+\fBfilesystem show\fR [<device>|<uuid>|<label>]\fR
+Show the btrfs filesystem with some additional info. If no argument is
+passed, \fBbtrfs\fR shows info of all the btrfs filesystems.
.TP
-\fBdevice balance\fR \fI<path>\fR
+\fBfilesystem balance\fR \fI<path>\fR
Balance the chunks of the filesystem identified by \fI<path>\fR
across the devices.
.TP
-\fBdevice add\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice add\fR\fI <device> [<device>...] <path>\fR
Add device(s) to the filesystem identified by \fI<path>\fR.
.TP
-\fBdevice delete\fR\fI <dev> [<dev>..] <path>\fR
+\fBdevice delete\fR\fI <device> [<device>...] <path>\fR
Remove device(s) from a filesystem identified by \fI<path>\fR.
.PP
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2010-12-05 17:47:45 +00:00
|
|
|
.I filesystem sync.
|
2010-03-11 21:32:50 +00:00
|
|
|
In this case
|
|
|
|
.I btrfs
|
2011-12-16 08:46:48 +00:00
|
|
|
returns filesystem sync
|
2010-03-11 21:32:50 +00:00
|
|
|
If a command is terminated by
|
|
|
|
.I --help
|
2011-01-23 15:31:07 +00:00
|
|
|
, the detailed help is showed. If the passed command matches more commands,
|
|
|
|
detailed help of all the matched commands is showed. For example
|
2010-03-11 21:32:50 +00:00
|
|
|
.I btrfs dev --help
|
|
|
|
shows the help of all
|
|
|
|
.I device*
|
2011-01-23 15:31:07 +00:00
|
|
|
commands.
|
2010-03-11 21:32:50 +00:00
|
|
|
|
|
|
|
.SH COMMANDS
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBsubvolume create\fP [-i \fI<qgroupid>\fP] [\fI<dest>\fP/]\fI<name>\fP
|
|
|
|
Create a subvolume \fI<name>\fR in \fI<dest>\fR.
|
|
|
|
If \fI<dest>\fR is not given subvolume \fI<name>\fR will be created in the
|
|
|
|
current directory.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fP
|
|
|
|
.IP "\fB-i\fP \fI<qgroupid>\fR" 5
|
|
|
|
Add the newly created subvolume to a qgroup. This option can be given multiple
|
|
|
|
times.
|
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-12-12 18:11:26 +00:00
|
|
|
\fBsubvolume delete\fR [\fIoptions\fP] \fI<subvolume>\fP [\fI<subvolume>...\fP]\fR
|
|
|
|
Delete the subvolume(s) from the filesystem. If \fI<subvolume>\fR is not a
|
|
|
|
subvolume, \fBbtrfs\fR returns an error but continues if there are more arguments
|
|
|
|
to process.
|
|
|
|
|
|
|
|
The corresponding directory is removed instantly but the data blocks are
|
|
|
|
removed later. The deletion does not involve full commit by default due to
|
|
|
|
performance reasons (as a consequence, the subvolume may appear again after a
|
|
|
|
crash). Use one of the --commit options to wait until the operation is safely
|
|
|
|
stored on the media.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fP
|
|
|
|
.IP "\fB-c|--commit-after\fP" 5
|
|
|
|
wait for transaction commit at the end of the operation
|
|
|
|
.IP "\fB-C|--commit-each\fP" 5
|
|
|
|
wait for transaction commit after deleting each subvolume
|
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBsubvolume list\fR [\fIoptions\fP] [-G [+|-]\fIvalue\fP] [-C [+|-]\fIvalue\fP] [--sort=rootid,gen,ogen,path] \fI<path>\fR
|
2010-03-11 21:32:50 +00:00
|
|
|
|
|
|
|
List the subvolumes present in the filesystem \fI<path>\fR. For every
|
2011-07-02 22:26:40 +00:00
|
|
|
subvolume the following information is shown by default.
|
2013-07-23 02:43:22 +00:00
|
|
|
ID \fI<ID>\fP top level \fI<ID>\fP path \fI<path>\fP
|
2011-07-02 22:26:40 +00:00
|
|
|
where path is the relative path of the subvolume to the \fItop level\fR
|
|
|
|
subvolume.
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
|
2011-07-02 22:26:40 +00:00
|
|
|
The subvolume's ID may be used by the \fBsubvolume set-default\fR command, or
|
2013-02-01 16:37:29 +00:00
|
|
|
at mount time via the \fIsubvolid=\fR option.
|
2011-07-02 22:26:40 +00:00
|
|
|
If \fI-p\fR is given, then \fIparent <ID>\fR is added to the output between ID
|
|
|
|
and top level. The parent's ID may be used at mount time via the
|
|
|
|
\fIsubvolrootid=\fR option.
|
2013-07-23 02:43:22 +00:00
|
|
|
.RS
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fIOptions\fP
|
|
|
|
.IP "\fB-p\fP" 5
|
|
|
|
print parent ID.
|
|
|
|
.IP "\fB-a\fP" 5
|
|
|
|
print all the subvolumes in the filesystem and distinguish between
|
|
|
|
absolute and relative path with respect to the given \fI<path>\fP.
|
|
|
|
.IP "\fB-c\fP" 5
|
|
|
|
print the ogeneration of the subvolume, aliases: ogen or origin generation.
|
|
|
|
.IP "\fB-g\fP" 5
|
|
|
|
print the generation of the subvolume.
|
|
|
|
.IP "\fB-o\fP" 5
|
|
|
|
print only subvolumes bellow specified <path>.
|
|
|
|
.IP "\fB-u\fP" 5
|
|
|
|
print the UUID of the subvolume.
|
|
|
|
.IP "\fB-q\fP" 5
|
|
|
|
print the parent uuid of subvolumes (and snapshots).
|
|
|
|
.IP "\fB-t\fP" 5
|
|
|
|
print the result as a table.
|
|
|
|
.IP "\fB-s\fP" 5
|
|
|
|
only snapshot subvolumes in the filesystem will be listed.
|
|
|
|
.IP "\fB-r\fP" 5
|
|
|
|
only readonly subvolumes in the filesystem will be listed.
|
|
|
|
.IP "\fB-G [+|-]\fIvalue\fP\fP" 5
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
list subvolumes in the filesystem that its generation is
|
2013-07-23 02:43:22 +00:00
|
|
|
>=, <= or = \fIvalue\fP. '+' means >= \fIvalue\fP, '-' means <= \fIvalue\fP, If there is
|
|
|
|
neither '+' nor '-', it means = \fIvalue\fP.
|
|
|
|
.IP "\fB-C [+|-]\fIvalue\fP" 5
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
list subvolumes in the filesystem that its ogeneration is
|
2013-07-23 02:43:22 +00:00
|
|
|
>=, <= or = \fIvalue\fP. The usage is the same to '-g' option.
|
|
|
|
.IP "\fB--sort=rootid,gen,ogen,path\fP" 5
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
list subvolumes in order by specified items.
|
2013-02-01 16:37:29 +00:00
|
|
|
you can add '+' or '-' in front of each items, '+' means ascending, '-'
|
Btrfs-progs: introduce -g -c --sort options into btrfs subvol list command
This patch introduces '-g' '-c' '--sort' options
The option '-g' can help you filter the subvolumes by the generation, you may
use it just like:
btrfs subvol list -g +/-value <path>
'+' means the generation of the subvolumes should >= the value you specified.
'-' means the generation should <= the value
If you don't input either '+' nor '-', this command will list the subvolumes
that their generation equals to the value.
However if you want to find gengeration between value1 and value2
you may use the above like:
btrfs sub list -g -value1 -g +value2 <path>
The option '-c' can help you filter the subvolumes by the ogeneration, you may
use it just like:
btrfs subvol list -c +/-value <path>
The usage is the same to '-g'
You might want to list subvolumes in order of some items, such as root id, gen
and so on, you can use '--sort'. Now you can sort the subvolumes by root id,
gen, ogen and path.
For example:
If you want to list subvolumes in order of rootid, you can use the option like
that:
btrfs sub list --sort=+/-rooid <path>
Here, '+' means the result is sorted by ascending order. '-' is by descending
order. If you don't specify either '+' nor '-', the result is sorted by
default - ascending order.
If you want to combine sort items, you do it like that:
btrfs sub list --sort=-rootid,+path,ogen,gen <path>
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
2012-09-19 09:21:51 +00:00
|
|
|
means descending. The default is ascending.
|
|
|
|
|
|
|
|
for \fB--sort\fP you can combine some items together by ',', just like
|
|
|
|
\f--sort=+ogen,-gen,path,rootid\fR.
|
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBsubvolume snapshot\fP [-r] \fI<source>\fP \fI<dest>\fP|[\fI<dest>\fP/]\fI<name>\fP
|
|
|
|
Create a writable/readonly snapshot of the subvolume \fI<source>\fR with the
|
|
|
|
name \fI<name>\fR in the \fI<dest>\fR directory.
|
|
|
|
If only \fI<dest>\fR is given, the subvolume will be named the basename of \fI<source>\fR.
|
|
|
|
If \fI<source>\fR is not a subvolume, \fBbtrfs\fR returns an error.
|
|
|
|
If \fI-r\fR is given, the snapshot will be readonly.
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2011-07-12 02:48:37 +00:00
|
|
|
\fBsubvolume get-default\fR\fI <path>\fR
|
|
|
|
Get the default subvolume of the filesystem \fI<path>\fR. The output format
|
|
|
|
is similar to \fBsubvolume list\fR command.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBsubvolume set-default\fR\fI <id> <path>\fR
|
|
|
|
Set the subvolume of the filesystem \fI<path>\fR which is mounted as
|
|
|
|
\fIdefault\fR. The subvolume is identified by \fI<id>\fR, which
|
|
|
|
is returned by the \fBsubvolume list\fR command.
|
|
|
|
.TP
|
|
|
|
|
2013-01-31 05:35:31 +00:00
|
|
|
\fBsubvolume find-new\fR\fI <subvolume> <last_gen>\fR
|
|
|
|
List the recently modified files in a subvolume, after \fI<last_gen>\fR ID.
|
|
|
|
.TP
|
|
|
|
|
2013-02-01 07:56:28 +00:00
|
|
|
\fBsubvolume show\fR\fI <path>\fR
|
|
|
|
Show information of a given subvolume in the \fI<path>\fR.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBfilesystem df\fP\fI <path>\fR
|
|
|
|
Show space usage information for a mount point.
|
|
|
|
.TP
|
2010-11-18 03:49:56 +00:00
|
|
|
|
2013-10-08 03:41:38 +00:00
|
|
|
\fBfilesystem show\fR [\fI--mounted\fP|\fI--all-devices\fP|\fI<uuid>\fR]\fR
|
|
|
|
Show the btrfs filesystem with some additional info. If no option or \fIUUID\fP
|
|
|
|
is passed, \fBbtrfs\fR shows information of all the btrfs filesystem both mounted
|
|
|
|
and unmounted.
|
|
|
|
If \fB--mounted\fP is passed, it would probe btrfs kernel to list mounted btrfs filesystem(s);
|
2013-07-23 02:43:22 +00:00
|
|
|
If \fB--all-devices\fP is passed, all the devices under /dev are scanned;
|
|
|
|
otherwise the devices list is extracted from the /proc/partitions file.
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBfilesystem sync\fR\fI <path> \fR
|
|
|
|
Force a sync for the filesystem identified by \fI<path>\fR.
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBfilesystem defragment\fP [\fIoptions\fP] \fI<file>\fP|\fI<dir>\fP [\fI<file>\fP|\fI<dir>...\fP]\fP
|
2013-10-01 15:31:47 +00:00
|
|
|
Defragment file data and/or directory metadata. If \fB-r\fP is passed,
|
|
|
|
files in \fIdir\fR will be defragmented recursively.
|
|
|
|
|
2011-01-23 15:31:07 +00:00
|
|
|
|
2011-12-16 08:46:48 +00:00
|
|
|
The start position and the number of bytes to defragment can be specified by
|
|
|
|
\fIstart\fR and \fIlen\fR. Any extent bigger than threshold will be
|
|
|
|
considered already defragged. Use 0 to take the kernel default, and use 1 to
|
|
|
|
say every single extent must be rewritten. You can also turn on compression in
|
|
|
|
defragment operations.
|
2013-07-23 02:43:22 +00:00
|
|
|
.RS
|
2010-11-18 03:49:56 +00:00
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
be verbose
|
|
|
|
.IP "\fB-c\fP" 5
|
|
|
|
compress file contents while defragmenting
|
2013-10-01 15:31:47 +00:00
|
|
|
.IP "\fB-r\fP" 5
|
|
|
|
defragment files recursively
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-f\fP" 5
|
|
|
|
flush filesystem after defragmenting
|
|
|
|
.IP "\fB-s \fIstart\fP\fP" 5
|
|
|
|
defragment only from byte \fIstart\fR onward
|
|
|
|
.IP "\fB-l \fIlen\fP\fP" 5
|
|
|
|
defragment only up to \fIlen\fR bytes
|
|
|
|
.IP "\fB-t \fIsize\fP\fP" 5
|
|
|
|
defragment only files at least \fIsize\fR bytes big
|
2011-01-23 15:31:07 +00:00
|
|
|
|
2012-10-29 17:53:20 +00:00
|
|
|
For \fBstart\fP, \fBlen\fP, \fBsize\fP it is possible to append a suffix
|
|
|
|
like \fBk\fP for 1 KBytes, \fBm\fP for 1 MBytes...
|
|
|
|
|
2011-12-16 08:46:48 +00:00
|
|
|
NOTE: defragmenting with kernels up to 2.6.37 will unlink COW-ed copies of data,
|
|
|
|
don't use it if you use snapshots, have de-duplicated your data or made
|
|
|
|
copies with \fBcp --reflink\fP.
|
2013-07-23 02:43:22 +00:00
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
|
|
|
.\"
|
|
|
|
.\" Some wording are extracted by the resize2fs man page
|
|
|
|
.\"
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBfilesystem resize\fP [\fIdevid\fP:][+/\-]\fI<size>\fP[gkm]|[\fIdevid\fP:]\fImax <path>\fR
|
2012-05-26 17:57:55 +00:00
|
|
|
Resize a filesystem identified by \fI<path>\fR for the underlying device
|
|
|
|
\fIdevid\fR. The \fIdevid\fR can be found with \fBbtrfs filesystem show\fR and
|
|
|
|
defaults to 1 if not specified.
|
2010-03-11 21:32:50 +00:00
|
|
|
The \fI<size>\fR parameter specifies the new size of the filesystem.
|
|
|
|
If the prefix \fI+\fR or \fI\-\fR is present the size is increased or decreased
|
|
|
|
by the quantity \fI<size>\fR.
|
|
|
|
If no units are specified, the unit of the \fI<size>\fR parameter defaults to
|
|
|
|
bytes. Optionally, the size parameter may be suffixed by one of the following
|
2011-12-16 08:46:48 +00:00
|
|
|
units designators: 'K', 'M', or 'G', kilobytes, megabytes, or gigabytes,
|
2010-03-11 21:32:50 +00:00
|
|
|
respectively.
|
|
|
|
|
|
|
|
If 'max' is passed, the filesystem will occupy all available space on the
|
2012-05-26 17:57:55 +00:00
|
|
|
device \fIdevid\fR.
|
2010-03-11 21:32:50 +00:00
|
|
|
|
|
|
|
The \fBresize\fR command \fBdoes not\fR manipulate the size of underlying
|
|
|
|
partition. If you wish to enlarge/reduce a filesystem, you must make sure you
|
|
|
|
can expand the partition before enlarging the filesystem and shrink the
|
2012-05-26 17:57:55 +00:00
|
|
|
partition after reducing the size of the filesystem. This can done using
|
|
|
|
\fBfdisk(8)\fR or \fBparted(8)\fR to delete the existing partition and recreate
|
|
|
|
it with the new desired size. When recreating the partition make sure to use
|
|
|
|
the same starting disk cylinder as before.
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBfilesystem label\fP [\fI<dev>\fP|\fI<mount_point>\fP] [\fInewlabel\fP]\fP
|
2013-06-17 21:45:23 +00:00
|
|
|
Show or update the label of a filesystem. \fI[<device>|<mountpoint>]\fR is used
|
|
|
|
to identify the filesystem.
|
2010-12-05 17:46:44 +00:00
|
|
|
If a \fInewlabel\fR optional argument is passed, the label is changed. The
|
2011-12-16 08:46:48 +00:00
|
|
|
following constraints exist for a label:
|
2010-12-05 17:46:44 +00:00
|
|
|
.IP
|
2013-06-17 21:45:23 +00:00
|
|
|
- the maximum allowable length shall be less than 256 chars
|
2013-07-23 02:43:22 +00:00
|
|
|
.TP
|
2010-12-05 17:46:44 +00:00
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fB[filesystem] balance start\fR [\fIoptions\fP] \fI<path>\fR
|
|
|
|
Balance chunks across the devices
|
|
|
|
Balance and/or convert (change allocation profile of) chunks that
|
|
|
|
passed all \fIfilters\fR in a comma-separated list of filters for a
|
|
|
|
particular chunk type.
|
|
|
|
If filter list is not given balance all chunks of that type.
|
|
|
|
In case none of the \fI-d\fR, \fI-m\fR or \fI-s\fR options is
|
|
|
|
given balance all chunks in a filesystem.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-d[\fIfilters\fP]\fR" 5
|
|
|
|
act on data chunks
|
|
|
|
.IP "\fB-m[\fIfilters\fP]\fR" 5
|
|
|
|
act on metadata chunks
|
|
|
|
.IP "\fB-s[\fIfilters\fP]\fR" 5
|
|
|
|
act on system chunks (only under -f)
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
be verbose
|
|
|
|
.IP "\fB-f\fP" 5
|
|
|
|
force reducing of metadata integrity
|
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fB[filesystem] balance pause\fR\fI <path>\fR
|
|
|
|
Pause running balance.
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fB[filesystem] balance cancel\fR\fI <path>\fR
|
|
|
|
Cancel running or paused balance.
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fB[filesystem] balance resume\fR\fI <path>\fR
|
|
|
|
Resume interrupted balance.
|
|
|
|
.TP
|
2012-05-15 09:30:39 +00:00
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fB[filesystem] balance status\fR [-v] \fI<path>\fR
|
|
|
|
Show status of running or paused balance.
|
2012-05-15 09:30:39 +00:00
|
|
|
.RS
|
2013-07-23 02:43:22 +00:00
|
|
|
|
2012-05-15 09:30:39 +00:00
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
be verbose
|
2012-05-15 09:30:39 +00:00
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2013-09-27 17:30:05 +00:00
|
|
|
\fBdevice add\fR\fI [-Kf] <dev> \fP[\fI<dev>...\fP] \fI<path>\fR
|
2010-03-11 21:32:50 +00:00
|
|
|
Add device(s) to the filesystem identified by \fI<path>\fR.
|
2013-09-17 14:54:01 +00:00
|
|
|
If applicable, a whole device discard (TRIM) operation is performed.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-K|--nodiscard\fP" 5
|
|
|
|
do not perform discard by default
|
2013-09-27 17:30:05 +00:00
|
|
|
.IP "\fB-f|--force\fP" 5
|
|
|
|
force overwrite of existing filesystem on the given disk(s)
|
2013-09-17 14:54:01 +00:00
|
|
|
.RE
|
2010-03-11 21:32:50 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBdevice delete\fR\fI <dev> \fP[\fI<dev>...\fP] \fI<path>\fR
|
2010-03-11 21:32:50 +00:00
|
|
|
Remove device(s) from a filesystem identified by \fI<path>\fR.
|
2011-06-15 19:55:25 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBdevice scan\fR [--all-devices|\fI<device> \fP[\fI<device>...\fP]\fR
|
2011-06-15 19:55:25 +00:00
|
|
|
If one or more devices are passed, these are scanned for a btrfs filesystem.
|
2013-10-08 03:41:38 +00:00
|
|
|
If no devices are passed, \fBbtrfs\fR uses block devices containing btrfs
|
|
|
|
filesystem as listed by blkid.
|
2011-06-15 19:55:25 +00:00
|
|
|
Finally, if \fB--all-devices\fP is passed, all the devices under /dev are
|
|
|
|
scanned.
|
|
|
|
.TP
|
2010-03-11 21:32:50 +00:00
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBdevice ready\fR \fI<device>\fR
|
|
|
|
Check device to see if it has all of it's devices in cache for mounting.
|
2012-05-07 12:00:20 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBdevice stats\fP [-z] {\fI<path>\fP|\fI<device>\fP}
|
|
|
|
Read and print the device IO stats for all devices of the filesystem
|
|
|
|
identified by \fI<path>\fR or for a single \fI<device>\fR.
|
2012-05-07 12:00:20 +00:00
|
|
|
.RS
|
2013-07-23 02:43:22 +00:00
|
|
|
|
2012-05-07 12:00:20 +00:00
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-z\fP" 5
|
|
|
|
Reset stats to zero after reading them.
|
2012-05-07 12:00:20 +00:00
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBscrub start\fP [-BdqrR] [-c \fIioprio_class\fP -n \fIioprio_classdata\fP] {\fI<path>\fP|\fI<device>\fP}
|
2011-07-18 12:37:25 +00:00
|
|
|
Start a scrub on all devices of the filesystem identified by \fI<path>\fR or on
|
|
|
|
a single \fI<device>\fR. Without options, scrub is started as a background
|
|
|
|
process. Progress can be obtained with the \fBscrub status\fR command. Scrubbing
|
|
|
|
involves reading all data from all disks and verifying checksums. Errors are
|
|
|
|
corrected along the way if possible.
|
2012-05-16 16:51:28 +00:00
|
|
|
.IP
|
|
|
|
The default IO priority of scrub is the idle class. The priority can be configured similar to the
|
|
|
|
.BR ionice (1)
|
|
|
|
syntax.
|
2011-07-18 12:37:25 +00:00
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-B\fP" 5
|
2011-07-18 12:37:25 +00:00
|
|
|
Do not background and print scrub statistics when finished.
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-d\fP" 5
|
2011-07-18 12:37:25 +00:00
|
|
|
Print separate statistics for each device of the filesystem (-B only).
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-q\fP" 5
|
2011-07-18 12:37:25 +00:00
|
|
|
Quiet. Omit error messages and statistics.
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-r\fP" 5
|
2011-07-18 12:37:25 +00:00
|
|
|
Read only mode. Do not attempt to correct anything.
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-R\fP" 5
|
|
|
|
Raw print mode. Print full data instead of summary.
|
|
|
|
.IP "\fB-c \fIioprio_class\fP" 5
|
2012-05-16 16:51:28 +00:00
|
|
|
Set IO priority class (see
|
|
|
|
.BR ionice (1)
|
|
|
|
manpage).
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-n \fIioprio_classdata\fP" 5
|
2012-05-16 16:51:28 +00:00
|
|
|
Set IO priority classdata (see
|
|
|
|
.BR ionice (1)
|
|
|
|
manpage).
|
2013-12-02 06:42:25 +00:00
|
|
|
.IP "\fB-f\fP" 5
|
|
|
|
force to check whether scrub has started or resumed in userspace.
|
|
|
|
this is useful when scrub stat record file is damaged.
|
2011-07-18 12:37:25 +00:00
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBscrub cancel\fP {\fI<path>\fP|\fI<device>\fP}
|
|
|
|
If a scrub is running on the filesystem identified by \fI<path>\fR, cancel it.
|
|
|
|
Progress is saved in the scrub progress file and scrubbing can be resumed later
|
|
|
|
using the \fBscrub resume\fR command.
|
|
|
|
If a \fI<device>\fR is given, the corresponding filesystem is found and
|
|
|
|
\fBscrub cancel\fP behaves as if it was called on that filesystem.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBscrub resume\fP [-BdqrR] [-c ioprio_class -n ioprio_classdata] {\fI<path>\fP|\fI<device>\fP}
|
2011-07-18 12:37:25 +00:00
|
|
|
Resume a canceled or interrupted scrub cycle on the filesystem identified by
|
|
|
|
\fI<path>\fR or on a given \fI<device>\fR. Does not start a new scrub if the
|
|
|
|
last scrub finished successfully.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.TP
|
|
|
|
see \fBscrub start\fP.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBscrub status\fP [-d] {\fI<path>\fP|\fI<device>\fP}
|
|
|
|
Show status of a running scrub for the filesystem identified by \fI<path>\fR or
|
|
|
|
for the specified \fI<device>\fR.
|
|
|
|
If no scrub is running, show statistics of the last finished or canceled scrub
|
|
|
|
for that filesystem or device.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-d\fP" 5
|
2011-07-18 12:37:25 +00:00
|
|
|
Print separate statistics for each device of the filesystem.
|
|
|
|
.RE
|
2011-07-08 10:25:11 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBcheck\fR [\fIoptions\fP] <device>\fR
|
|
|
|
Check an unmounted btrfs filesystem.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-s|--support \fI<superblock>\fP\fR" 5
|
|
|
|
use this superblock copy.
|
|
|
|
.IP "\fB--repair\fP" 5
|
|
|
|
try to repair the filesystem.
|
|
|
|
.IP "\fB--init-csum-tree\fP" 5
|
|
|
|
create a new CRC tree.
|
|
|
|
.IP "\fB--init-extent-tree\fP" 5
|
|
|
|
create a new extent tree.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2013-09-17 15:21:21 +00:00
|
|
|
\fBrescue chunk-recover\fR [\fIoptions\fP] <device>\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
Recover the chunk tree by scanning the devices one by one.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-y\fP" 5
|
|
|
|
assume an answer of 'yes' to all questions.
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
verbose mode.
|
|
|
|
.IP "\fB-h\fP" 5
|
|
|
|
help.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2013-11-14 13:40:43 +00:00
|
|
|
\fBrescue super-recover\fR [\fIoptions\fP] <device>\fR
|
|
|
|
Recover bad superblocks from good copies.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-y\fP" 5
|
|
|
|
assume an answer of 'yes' to all questions.
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
verbose mode.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBrestore\fR [\fIoptions\fP] <device>\fR
|
|
|
|
Try to restore files from a damaged filesystem(unmounted).
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-s\fP" 5
|
|
|
|
get snapshots.
|
2013-08-17 13:16:02 +00:00
|
|
|
.IP "\fB-x\fP" 5
|
|
|
|
get extended attributes.
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
verbose.
|
|
|
|
.IP "\fB-i\fP" 5
|
|
|
|
ignore errors.
|
|
|
|
.IP "\fB-o\fP" 5
|
|
|
|
overwrite.
|
|
|
|
.IP "\fB-t \fI<location>\fP\fP" 5
|
|
|
|
tree location.
|
|
|
|
.IP "\fB-f \fI<offset>\fP\fP" 5
|
|
|
|
filesystem location.
|
|
|
|
.IP "\fB-u \fI<block>\fP\fP" 5
|
|
|
|
super mirror.
|
|
|
|
.IP "\fB-r \fI<rootid>\fP\fP" 5
|
|
|
|
root objectid.
|
|
|
|
.IP "\fB-d\fP" 5
|
|
|
|
find dir.
|
|
|
|
.IP "\fB-l\fP" 5
|
|
|
|
list tree roots.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2011-07-08 10:25:11 +00:00
|
|
|
\fBinspect-internal inode-resolve\fP [-v] \fI<inode>\fP \fI<path>\fP
|
|
|
|
Resolves an <inode> in subvolume <path> to all filesystem paths.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-v\fP" 5
|
2011-07-08 10:25:11 +00:00
|
|
|
verbose mode. print count of returned paths and ioctl() return value
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
2012-08-31 05:40:44 +00:00
|
|
|
\fBinspect-internal logical-resolve\fP [-Pv] [-s bufsize] \fI<logical>\fP \fI<path>\fP
|
2011-07-08 10:25:11 +00:00
|
|
|
Resolves a <logical> address in the filesystem mounted at <path> to all inodes.
|
|
|
|
By default, each inode is then resolved to a file system path (similar to the
|
|
|
|
\fBinode-resolve\fP subcommand).
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-P\fP" 5
|
2011-07-08 10:25:11 +00:00
|
|
|
skip the path resolving and print the inodes instead
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-v\fP" 5
|
2011-07-08 10:25:11 +00:00
|
|
|
verbose mode. print count of returned paths and all ioctl() return values
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-s \fI<bufsize>\fP" 5
|
2012-08-31 05:40:44 +00:00
|
|
|
set inode container's size. This is used to increase inode container's size in case it is
|
|
|
|
not enough to read all the resolved results. The max value one can set is 64k.
|
2011-07-08 10:25:11 +00:00
|
|
|
.RE
|
2013-03-21 08:33:37 +00:00
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBinspect-internal subvolid-resolve\fP \fI<subvolid> <path>\fP
|
2013-04-23 10:18:55 +00:00
|
|
|
Get file system paths for the given subvolume ID.
|
|
|
|
.TP
|
|
|
|
|
2013-09-18 16:19:30 +00:00
|
|
|
\fBinspect-internal rootid\fP \fI<path>\fP
|
|
|
|
For a given file or directory, return the containing tree root id. For a
|
|
|
|
subvolume return it's own tree id.
|
|
|
|
|
|
|
|
The result is undefined for the so-called empty subvolumes (identified by inode number 2).
|
|
|
|
.TP
|
|
|
|
|
2013-12-16 15:47:10 +00:00
|
|
|
\fBsend\fP [-ve] [-p \fI<parent>\fP] [-c \fI<clone-src>\fP] [-f \fI<outfile>\fP] \fI<subvol>\fP [\fI<subvol>...\fP]
|
|
|
|
Send the subvolume(s) to stdout.
|
|
|
|
Sends the subvolume(s) specified by \fI<subvol>\fR to stdout.
|
2013-07-23 02:43:22 +00:00
|
|
|
By default, this will send the whole subvolume. To do an incremental
|
|
|
|
send, use '\fI-p <parent>\fR'. If you want to allow btrfs to clone from
|
|
|
|
any additional local snapshots, use '\fI-c <clone-src>\fR' (multiple times
|
|
|
|
where applicable). You must not specify clone sources unless you
|
|
|
|
guarantee that these snapshots are exactly in the same state on both
|
2013-12-16 15:47:10 +00:00
|
|
|
sides, the sender and the receiver. It is allowed to omit the '\fI-p <parent>\fR'
|
|
|
|
option when '\fI-c <clone-src>\fR' options are given, in
|
2013-07-23 02:43:22 +00:00
|
|
|
which case '\fBbtrfs send\fP' will determine a suitable parent among the
|
|
|
|
clone sources itself.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
Enable verbose debug output. Each occurrence of this option increases the
|
|
|
|
verbose level more.
|
2013-12-16 15:47:10 +00:00
|
|
|
.IP "\fB-e\fP" 5
|
|
|
|
If sending multiple subvols at once, use the new format and omit the <end cmd> between the subvols.
|
2013-07-23 02:43:22 +00:00
|
|
|
.IP "\fB-p \fI<parent>\fP" 5
|
|
|
|
Send an incremental stream from \fI<parent>\fR to \fI<subvol>\fR.
|
|
|
|
.IP "\fB-c \fI<clone-src>\fP" 5
|
|
|
|
Use this snapshot as a clone source for an incremental send (multiple allowed).
|
|
|
|
.IP "\fB-f \fI<outfile>\fP" 5
|
|
|
|
Output is normally written to stdout. To write to a file, use this option.
|
|
|
|
An alternative would be to use pipes.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBreceive\fP [-ve] [-f \fI<infile>\fR] \fI<mount>\fR
|
|
|
|
Receive subvolumes from stdin.
|
|
|
|
Receives one or more subvolumes that were previously
|
|
|
|
sent with btrfs send. The received subvolumes are stored
|
|
|
|
into \fI<mount>\fP.
|
2013-12-18 09:56:33 +00:00
|
|
|
btrfs receive will fail with the following case:
|
|
|
|
|
|
|
|
1.a receiving subvolume already exists.
|
|
|
|
|
|
|
|
2.a previously received subvolume was changed after it was received.
|
|
|
|
|
|
|
|
3.default subvolume is changed or you don't mount btrfs filesystem with
|
|
|
|
fs tree.
|
|
|
|
|
|
|
|
After receiving a subvolume, it is immediately set to read only.
|
2013-07-23 02:43:22 +00:00
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-v\fP" 5
|
|
|
|
Enable verbose debug output. Each occurrence of this option increases the
|
|
|
|
verbose level more.
|
|
|
|
.IP "\fB-f \fI<infile>\fR" 5
|
|
|
|
By default, btrfs receive uses stdin to receive the subvolumes.
|
|
|
|
Use this option to specify a file to use instead.
|
|
|
|
.IP "\fB-e\fP" 5
|
|
|
|
Terminate after receiving an <end cmd> in the data stream.
|
|
|
|
Without this option, the receiver terminates only if an error is recognized or on EOF.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBquota enable\fR \fI<path>\fR
|
|
|
|
Enable subvolume quota support for a filesystem.
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBquota disable\fR \fI<path>\fR
|
|
|
|
Disable subvolume quota support for a filesystem.
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBquota rescan\fR [-s] \fI<path>\fR
|
|
|
|
Trash all qgroup numbers and scan the metadata again with the current config.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-s\fP" 5
|
|
|
|
show status of a running rescan operation.
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBqgroup assign\fP \fI<src> <dst> <path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Enable subvolume qgroup support for a filesystem.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBqgroup remove\fP \fI<src> <dst> <path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Remove a subvol from a quota group.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBqgroup create\fP \fI<qgroupid> <path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Create a subvolume quota group.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBqgroup destroy\fP \fI<qgroupid> <path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Destroy a subvolume quota group.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBqgroup show\fP \fI<path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Show all subvolume quota groups.
|
|
|
|
.TP
|
|
|
|
|
2013-07-23 02:43:22 +00:00
|
|
|
\fBqgroup limit\fP [\fIoptions\fP] \fI<size>\fP|\fBnone\fP [\fI<qgroupid>\fP] \fI<path>\fP
|
2013-03-21 08:33:37 +00:00
|
|
|
Limit the size of a subvolume quota group.
|
2013-07-23 02:43:22 +00:00
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBreplace start\fR [-Bfr] \fI<srcdev>\fP|\fI<devid> <targetdev> <path>\fR
|
|
|
|
Replace device of a btrfs filesystem.
|
|
|
|
On a live filesystem, duplicate the data to the target device which
|
|
|
|
is currently stored on the source device. If the source device is not
|
|
|
|
available anymore, or if the \fB-r\fR option is set, the data is built
|
|
|
|
only using the RAID redundancy mechanisms. After completion of the
|
|
|
|
operation, the source device is removed from the filesystem.
|
|
|
|
If the \fI<srcdev>\fR is a numerical value, it is assumed to be the device id
|
|
|
|
of the filesystem which is mounted at mount_point, otherwise is is
|
|
|
|
the path to the source device. If the source device is disconnected,
|
|
|
|
from the system, you have to use the \fIdevid\fR parameter format.
|
|
|
|
The \fI<targetdev>\fP needs to be same size or larger than the \fI<srcdev>\fR.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-r\fP" 5
|
|
|
|
only read from \fI<srcdev>\fR if no other zero-defect mirror exists (enable
|
|
|
|
this if your drive has lots of read errors, the access would be very slow)
|
|
|
|
.IP "\fB-f\fP" 5
|
|
|
|
force using and overwriting \fI<targetdev>\fR even if it looks like
|
|
|
|
containing a valid btrfs filesystem. A valid filesystem is
|
|
|
|
assumed if a btrfs superblock is found which contains a
|
|
|
|
correct checksum. Devices which are currently mounted are
|
|
|
|
never allowed to be used as the \fI<targetdev>\fR
|
|
|
|
.IP "\fB-B\fP" 5
|
|
|
|
do not background
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBreplace status\fR [-1] \fI<mount_point>\fR
|
|
|
|
Print status and progress information of a running device replace operation.
|
|
|
|
.RS
|
|
|
|
|
|
|
|
\fIOptions\fR
|
|
|
|
.IP "\fB-1\fP" 5
|
|
|
|
print once instead of print continuously until the replace
|
|
|
|
operation finishes (or is canceled)
|
|
|
|
.RE
|
|
|
|
.TP
|
|
|
|
|
|
|
|
\fBreplace cancel\fR \fI<mount_point>\fR
|
|
|
|
Cancel a running device replace operation.
|
2013-03-21 08:33:37 +00:00
|
|
|
.RE
|
2011-07-18 12:37:25 +00:00
|
|
|
|
2010-03-11 21:32:50 +00:00
|
|
|
.SH EXIT STATUS
|
|
|
|
\fBbtrfs\fR returns a zero exist status if it succeeds. Non zero is returned in
|
|
|
|
case of failure.
|
|
|
|
|
|
|
|
.SH AVAILABILITY
|
|
|
|
.B btrfs
|
|
|
|
is part of btrfs-progs. Btrfs filesystem is currently under heavy development,
|
|
|
|
and not suitable for any uses other than benchmarking and review.
|
|
|
|
Please refer to the btrfs wiki http://btrfs.wiki.kernel.org for
|
|
|
|
further details.
|
|
|
|
.SH SEE ALSO
|
2012-05-16 16:51:28 +00:00
|
|
|
.BR mkfs.btrfs (8),
|
|
|
|
.BR ionice (1)
|