# btrfs(8) - man - phpman

> **TLDR:** A filesystem based on the copy-on-write (COW) principle for Linux.
>
- Create subvolume:
  `sudo btrfs {{su|subvolume}} {{c|create}} {{path/to/subvolume}}`
- List subvolumes:
  `sudo btrfs {{su|subvolume}} {{l|list}} {{path/to/mount_point}}`
- Show space usage information:
  `sudo btrfs {{f|filesystem}} df {{path/to/mount_point}}`
- Enable quota:
  `sudo btrfs {{qu|quota}} {{e|enable}} {{path/to/subvolume}}`
- Show quota:
  `sudo btrfs {{qg|qgroup}} {{s|show}} {{path/to/subvolume}}`

*Source: tldr-pages*

---

[BTRFS(8)](https://www.chedong.com/phpMan.php/man/BTRFS/8/markdown)                                    Btrfs Manual                                    [BTRFS(8)](https://www.chedong.com/phpMan.php/man/BTRFS/8/markdown)



## NAME
       btrfs - a toolbox to manage btrfs filesystems

## SYNOPSIS
       **btrfs** _<command>_ [_<args>_]

## DESCRIPTION
       The **btrfs** utility is a toolbox for managing btrfs filesystems. There are command groups to
       work with subvolumes, devices, for whole filesystem or other specific actions. See section
       **COMMANDS**.

       There are also standalone tools for some tasks like **btrfs-convert** or **btrfstune** that were
       separate historically and/or haven’t been merged to the main utility. See section _STANDALONE_
       _TOOLS_ for more details.

       For other topics (mount options, etc) please refer to the separate manual page [**btrfs**(5)](https://www.chedong.com/phpMan.php/man/btrfs/5/markdown).

## COMMAND SYNTAX
       Any command name can be shortened so long as the shortened form is unambiguous, however, it
       is recommended to use full command names in scripts. All command groups have their manual
       page named **btrfs-**_<group>_.

       For example: it is possible to run **btrfs** **sub** **snaps** instead of **btrfs** **subvolume** **snapshot**. But
       **btrfs** **file** **s** is not allowed, because **file** **s** may be interpreted both as **filesystem** **show** and as
       **filesystem** **sync**.

       If the command name is ambiguous, the list of conflicting options is printed.

       For an overview of a given command use _btrfs_ _command_ _--help_ or _btrfs_ _[command...]_ _--help_
       _--full_ to print all available options.

## COMMANDS
### balance
           Balance btrfs filesystem chunks across single or several devices.

           See [**btrfs-balance**(8)](https://www.chedong.com/phpMan.php/man/btrfs-balance/8/markdown) for details.

### check
           Do off-line check on a btrfs filesystem.

           See [**btrfs-check**(8)](https://www.chedong.com/phpMan.php/man/btrfs-check/8/markdown) for details.

### device
           Manage devices managed by btrfs, including add/delete/scan and so on.

           See [**btrfs-device**(8)](https://www.chedong.com/phpMan.php/man/btrfs-device/8/markdown) for details.

### filesystem
           Manage a btrfs filesystem, including label setting/sync and so on.

           See [**btrfs-filesystem**(8)](https://www.chedong.com/phpMan.php/man/btrfs-filesystem/8/markdown) for details.

### inspect-internal
           Debug tools for developers/hackers.

           See [**btrfs-inspect-internal**(8)](https://www.chedong.com/phpMan.php/man/btrfs-inspect-internal/8/markdown) for details.

### property
           Get/set a property from/to a btrfs object.

           See [**btrfs-property**(8)](https://www.chedong.com/phpMan.php/man/btrfs-property/8/markdown) for details.

### qgroup
           Manage quota group(qgroup) for btrfs filesystem.

           See [**btrfs-qgroup**(8)](https://www.chedong.com/phpMan.php/man/btrfs-qgroup/8/markdown) for details.

### quota
           Manage quota on btrfs filesystem like enabling/rescan and etc.

           See [**btrfs-quota**(8)](https://www.chedong.com/phpMan.php/man/btrfs-quota/8/markdown) and [**btrfs-qgroup**(8)](https://www.chedong.com/phpMan.php/man/btrfs-qgroup/8/markdown) for details.

### receive
           Receive subvolume data from stdin/file for restore and etc.

           See [**btrfs-receive**(8)](https://www.chedong.com/phpMan.php/man/btrfs-receive/8/markdown) for details.

### replace
           Replace btrfs devices.

           See [**btrfs-replace**(8)](https://www.chedong.com/phpMan.php/man/btrfs-replace/8/markdown) for details.

### rescue
           Try to rescue damaged btrfs filesystem.

           See [**btrfs-rescue**(8)](https://www.chedong.com/phpMan.php/man/btrfs-rescue/8/markdown) for details.

### restore
           Try to restore files from a damaged btrfs filesystem.

           See [**btrfs-restore**(8)](https://www.chedong.com/phpMan.php/man/btrfs-restore/8/markdown) for details.

### scrub
           Scrub a btrfs filesystem.

           See [**btrfs-scrub**(8)](https://www.chedong.com/phpMan.php/man/btrfs-scrub/8/markdown) for details.

### send
           Send subvolume data to stdout/file for backup and etc.

           See [**btrfs-send**(8)](https://www.chedong.com/phpMan.php/man/btrfs-send/8/markdown) for details.

### subvolume
           Create/delete/list/manage btrfs subvolume.

           See [**btrfs-subvolume**(8)](https://www.chedong.com/phpMan.php/man/btrfs-subvolume/8/markdown) for details.

## STANDALONE TOOLS
       New functionality could be provided using a standalone tool. If the functionality proves to
       be useful, then the standalone tool is declared obsolete and its functionality is copied to
       the main tool. Obsolete tools are removed after a long (years) depreciation period.

       Tools that are still in active use without an equivalent in **btrfs**:

### btrfs-convert
           in-place conversion from ext2/3/4 filesystems to btrfs

### btrfstune
           tweak some filesystem properties on a unmounted filesystem

### btrfs-select-super
           rescue tool to overwrite primary superblock from a spare copy

### btrfs-find-root
           rescue helper to find tree roots in a filesystem

       Deprecated and obsolete tools:

### btrfs-debug-tree
           moved to **btrfs** **inspect-internal** **dump-tree**. Removed from source distribution.

### btrfs-show-super
           moved to **btrfs** **inspect-internal** **dump-super**, standalone removed.

### btrfs-zero-log
           moved to **btrfs** **rescue** **zero-log**, standalone removed.

       For space-constrained environments, it’s possible to build a single binary with functionality
       of several standalone tools. This is following the concept of busybox where the file name
       selects the functionality. This works for symlinks or hardlinks. The full list can be
       obtained by **btrfs** **help** **--box**.

## EXIT STATUS
       **btrfs** returns a zero exit status if it succeeds. Non zero is returned in case of failure.

## AVAILABILITY
       **btrfs** is part of btrfs-progs. Please refer to the btrfs wiki **<http://btrfs.wiki.kernel.org>** for
       further details.

## SEE ALSO
       [**btrfs**(5)](https://www.chedong.com/phpMan.php/man/btrfs/5/markdown), [**btrfs-balance**(8)](https://www.chedong.com/phpMan.php/man/btrfs-balance/8/markdown), [**btrfs-check**(8)](https://www.chedong.com/phpMan.php/man/btrfs-check/8/markdown), [**btrfs-convert**(8)](https://www.chedong.com/phpMan.php/man/btrfs-convert/8/markdown), [**btrfs-device**(8)](https://www.chedong.com/phpMan.php/man/btrfs-device/8/markdown),
       [**btrfs-filesystem**(8)](https://www.chedong.com/phpMan.php/man/btrfs-filesystem/8/markdown), [**btrfs-inspect-internal**(8)](https://www.chedong.com/phpMan.php/man/btrfs-inspect-internal/8/markdown), [**btrfs-property**(8)](https://www.chedong.com/phpMan.php/man/btrfs-property/8/markdown), [**btrfs-qgroup**(8)](https://www.chedong.com/phpMan.php/man/btrfs-qgroup/8/markdown),
       [**btrfs-quota**(8)](https://www.chedong.com/phpMan.php/man/btrfs-quota/8/markdown), [**btrfs-receive**(8)](https://www.chedong.com/phpMan.php/man/btrfs-receive/8/markdown), [**btrfs-replace**(8)](https://www.chedong.com/phpMan.php/man/btrfs-replace/8/markdown), [**btrfs-rescue**(8)](https://www.chedong.com/phpMan.php/man/btrfs-rescue/8/markdown), [**btrfs-restore**(8)](https://www.chedong.com/phpMan.php/man/btrfs-restore/8/markdown),
       [**btrfs-scrub**(8)](https://www.chedong.com/phpMan.php/man/btrfs-scrub/8/markdown), [**btrfs-send**(8)](https://www.chedong.com/phpMan.php/man/btrfs-send/8/markdown), [**btrfs-subvolume**(8)](https://www.chedong.com/phpMan.php/man/btrfs-subvolume/8/markdown), [**btrfstune**(8)](https://www.chedong.com/phpMan.php/man/btrfstune/8/markdown), [**mkfs.btrfs**(8)](https://www.chedong.com/phpMan.php/man/mkfs.btrfs/8/markdown)



Btrfs v5.16.2                                02/16/2022                                     [BTRFS(8)](https://www.chedong.com/phpMan.php/man/BTRFS/8/markdown)
