Documentation/admin-guide/xfs.rst

Source file repositories/reference/linux-study-clean/Documentation/admin-guide/xfs.rst

File Facts

System
Linux kernel
Corpus path
Documentation/admin-guide/xfs.rst
Extension
.rst
Size
22719 bytes
Lines
564
Domain
Support Tooling And Documentation
Bucket
Documentation
Inferred role
Support Tooling And Documentation: documentation
Status
atlas-only

Why This File Exists

Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.

Dependency Surface

Detected Declarations

Annotated Snippet

.. SPDX-License-Identifier: GPL-2.0

======================
The SGI XFS Filesystem
======================

XFS is a high performance journaling filesystem which originated
on the SGI IRIX platform.  It is completely multi-threaded, can
support large files and large filesystems, extended attributes,
variable block sizes, is extent based, and makes extensive use of
Btrees (directories, extents, free space) to aid both performance
and scalability.

Refer to the documentation at https://xfs.wiki.kernel.org/
for further details.  This implementation is on-disk compatible
with the IRIX version of XFS.


Mount Options
=============

When mounting an XFS filesystem, the following options are accepted.

  allocsize=size
	Sets the buffered I/O end-of-file preallocation size when
	doing delayed allocation writeout (default size is 64KiB).
	Valid values for this option are page size (typically 4KiB)
	through to 1GiB, inclusive, in power-of-2 increments.

	The default behaviour is for dynamic end-of-file
	preallocation size, which uses a set of heuristics to
	optimise the preallocation size based on the current
	allocation patterns within the file and the access patterns
	to the file. Specifying a fixed ``allocsize`` value turns off
	the dynamic behaviour.

  discard or nodiscard (default)
	Enable/disable the issuing of commands to let the block
	device reclaim space freed by the filesystem.  This is
	useful for SSD devices, thinly provisioned LUNs and virtual
	machine images, but may have a performance impact.

	Note: It is currently recommended that you use the ``fstrim``
	application to ``discard`` unused blocks rather than the ``discard``
	mount option because the performance impact of this option
	is quite severe.

  grpid/bsdgroups or nogrpid/sysvgroups (default)
	These options define what group ID a newly created file
	gets.  When ``grpid`` is set, it takes the group ID of the
	directory in which it is created; otherwise it takes the
	``fsgid`` of the current process, unless the directory has the
	``setgid`` bit set, in which case it takes the ``gid`` from the
	parent directory, and also gets the ``setgid`` bit set if it is
	a directory itself.

  filestreams
	Make the data allocator use the filestreams allocation mode
	across the entire filesystem rather than just on directories
	configured to use it.

  inode32 or inode64 (default)
	When ``inode32`` is specified, it indicates that XFS limits
	inode creation to locations which will not result in inode
	numbers with more than 32 bits of significance.

	When ``inode64`` is specified, it indicates that XFS is allowed
	to create inodes at any location in the filesystem,
	including those which will result in inode numbers occupying
	more than 32 bits of significance.

Annotation

Implementation Notes