From Fedora Project Wiki

({{autolang|base=yes}})
(One intermediate revision by one other user not shown)
Line 1: Line 1:
= Btrfs filesystem **DRAFT** =
{{autolang|base=yes}}
 
= Btrfs filesystem =


== Summary ==
== Summary ==
Btrfs is a new copy on write filesystem for Linux aimed at implementing advanced features while focusing on fault tolerance, repair and easy administration. Initially developed by Oracle, Btrfs is licensed under the GPL and open for contribution from anyone.
Btrfs is a copy on write filesystem for Linux aimed at implementing advanced features while focusing on fault tolerance, repair and easy administration. It provides multiple device storage pooling, RAID-like functionality, fast snapshot creation, and checksumming of data and metadata. Initially developed by Oracle, Btrfs is licensed under the GPL and open for contribution from anyone.


For more detailed information can be found at the [http://btrfs.wiki.kernel.org Btrfs homepage].
For more detailed information can be found at the [https://btrfs.wiki.kernel.org/index.php/Main_Page Btrfs homepage].


== Purpose ==
== Purpose ==
The purpose of this page is not to duplicate information that can be found on other sites both internal and external but to consolidate and organize information and to make it Fedora specific where appropriate.
This page provides Fedora specific information on Btrfs support.
 
== Stability status and support ==
Fedora maintains fairly recent kernels and btrfs-progs that are typically identical to upstream. The best resources are the Btrfs Wiki and mailing list.
 
The current [https://btrfs.wiki.kernel.org/index.php/Status stability status] page.
 
[https://btrfs.wiki.kernel.org/index.php/Btrfs_mailing_list Mailing list] information.


== Btrfs support in Fedora ==
== Btrfs support in Fedora ==
* Btrfs has been available for testing as early as Fedora 11 but required a special boot parameter to be passed to [[Anaconda]] during installation.
* Btrfs has been available as an installation time option as early as Fedora 11.
* In Fedora 15 it is available without a special boot parameter.
* All Fedora products include Btrfs support in the kernel, and user space tools are installed by default.
* As of Fedora 16 it is slated to be the default filesystem.


== Installing ==
== Installing ==
Filesystem support is built into the kernel but you'll probably want to install the userspace programs using [[dnf|DNF]]:
* The Fedora installer, Anaconda, provides Btrfs as an option in Manual Partitioning.
<pre>
* The Btrfs partition scheme preset creates an ext4 /boot, swap, and a Btrfs pool. Two subvolumes, root and home, are created from that pool and mounted at / and /home respectively.
dnf install btrfs-progs
* Additional mount points using Btrfs will also have corresponding subvolumes created based on the Name field. Subvolumes do not have a size, so the Desired Capacity field when creating new mount points is ignored and can be left blank.
</pre>
 
Or with YUM:
<pre>
yum install btrfs-progs
</pre>


== Conversions from Ext3/Ext4 volumes to Btrfs (and back!) ==
== Conversions from Ext3/Ext4 volumes to Btrfs (and back!) ==
{{admon/important|Although Btrfs does not need LVM, if you already are using it then converting your volume does not remove LVM.}}
{{admon/important|Although Btrfs does not need LVM, if you already are using it then converting your volume does not remove LVM.}}
* It is possible to convert back to Ext3/Ext4 as the metadata is stored as a subvolume. Once you delete the subvolume the conversion is permanent.
* The convert code has been rewritten as of btrfs-progs 4.6, it's advised to avoid older versions.
* Some generic instructions can be found [http://btrfs.wiki.kernel.org/index.php/Conversion_from_Ext3 here].
* Check the upstream Btrfs changelog for the most recent recommended version of btrfs-progs.
* Some untested (by me) instructions on fedoraforum.org are [http://www.fedoraforum.org/forum/showthread.php?t=246520 here].
* The most recent recommended btrf-progs may not be in the Fedora repository version you're using, it can be found in Koji.
* Btrfs Wiki has more information on [https://btrfs.wiki.kernel.org/index.php/Conversion_from_Ext3 conversion and rollback.]


== Frequently Asked Question(s) ==
== Frequently Asked Question(s) ==
* Why use (or not use) Btrfs?
* Why use (or not use) Btrfs?
** The subvolume capability negates the need for LVM.
** Data integrity: detection of corrupt metadata and data, automatic repair when there's redundancy.
** Filesystem based [http://btrfs.wiki.kernel.org/index.php/Using_Btrfs_with_Multiple_Devices RAID 0/1/10].
** Fast snapshot creation, btrfs send/receive snapshots for replicating and backup.
** Online resizing and addition/removal of disks.
** Online resizing and addition/removal of disks.
** Btrfs currently has limited fsck capability so make sure you backup your data!
** Filesystem based [http://btrfs.wiki.kernel.org/index.php/Using_Btrfs_with_Multiple_Devices RAID 0/1/10/5/6]. See the Btrfs [https://btrfs.wiki.kernel.org/index.php/Status status page] for feature stability. Some features are considered experimental!
** 'btrfs check' a.k.a. btrfsck, is safe. However, while --repair should be safe, it comes with many warnings. See 'man btrfs check'.
** If a Btrfs volume fails to mount, try 'mount -o usebackuproot'. If that also fails report the issue on the Btrfs mailing list, including the output from 'btrfs check' without --repair.
 
 


[[Category:btrfs|btrfs]]
[[Category:btrfs|btrfs]]

Revision as of 16:13, 9 March 2017

Btrfs filesystem

Summary

Btrfs is a copy on write filesystem for Linux aimed at implementing advanced features while focusing on fault tolerance, repair and easy administration. It provides multiple device storage pooling, RAID-like functionality, fast snapshot creation, and checksumming of data and metadata. Initially developed by Oracle, Btrfs is licensed under the GPL and open for contribution from anyone.

For more detailed information can be found at the Btrfs homepage.

Purpose

This page provides Fedora specific information on Btrfs support.

Stability status and support

Fedora maintains fairly recent kernels and btrfs-progs that are typically identical to upstream. The best resources are the Btrfs Wiki and mailing list.

The current stability status page.

Mailing list information.

Btrfs support in Fedora

  • Btrfs has been available as an installation time option as early as Fedora 11.
  • All Fedora products include Btrfs support in the kernel, and user space tools are installed by default.

Installing

  • The Fedora installer, Anaconda, provides Btrfs as an option in Manual Partitioning.
  • The Btrfs partition scheme preset creates an ext4 /boot, swap, and a Btrfs pool. Two subvolumes, root and home, are created from that pool and mounted at / and /home respectively.
  • Additional mount points using Btrfs will also have corresponding subvolumes created based on the Name field. Subvolumes do not have a size, so the Desired Capacity field when creating new mount points is ignored and can be left blank.

Conversions from Ext3/Ext4 volumes to Btrfs (and back!)

Important.png
Although Btrfs does not need LVM, if you already are using it then converting your volume does not remove LVM.
  • The convert code has been rewritten as of btrfs-progs 4.6, it's advised to avoid older versions.
  • Check the upstream Btrfs changelog for the most recent recommended version of btrfs-progs.
  • The most recent recommended btrf-progs may not be in the Fedora repository version you're using, it can be found in Koji.
  • Btrfs Wiki has more information on conversion and rollback.

Frequently Asked Question(s)

  • Why use (or not use) Btrfs?
    • Data integrity: detection of corrupt metadata and data, automatic repair when there's redundancy.
    • Fast snapshot creation, btrfs send/receive snapshots for replicating and backup.
    • Online resizing and addition/removal of disks.
    • Filesystem based RAID 0/1/10/5/6. See the Btrfs status page for feature stability. Some features are considered experimental!
    • 'btrfs check' a.k.a. btrfsck, is safe. However, while --repair should be safe, it comes with many warnings. See 'man btrfs check'.
    • If a Btrfs volume fails to mount, try 'mount -o usebackuproot'. If that also fails report the issue on the Btrfs mailing list, including the output from 'btrfs check' without --repair.