xfs_rtcp
Control XFS real-time subvolumes
SYNOPSIS
xfs_rtcp [ -d data_device ] [ -r rt_device ] command [ options ]
PARAMETERS
-d data_device
Specifies the device containing the data section of the XFS filesystem. If not specified, the command will try to find the data device within the filesystem's superblock.
-r rt_device
Specifies the device containing the realtime section of the XFS filesystem. If not specified, the command assumes that data and realtime sections reside on the same device.
add inode extent_number
Adds an association between the specified inode number and the realtime extent_number. Subsequent I/O to that inode will be directed to the specified realtime extent.
delete inode
Deletes the association for the specified inode from the realtime section.
query inode
Queries the realtime extent number associated with the specified inode.
rebuild
Rebuilds the realtime extent maps from the filesystem data. This can fix inconsistencies.
-v
Verbose mode, provides additional debugging information.
DESCRIPTION
The `xfs_rtcp` command is used to control the realtime section of an XFS filesystem. It allows for operations such as creating, modifying, and deleting realtime extents. Realtime extents are contiguous regions on disk specifically allocated for large, sequential data streams, typically used for audio or video files. Using a realtime section can improve performance by reducing fragmentation and ensuring consistent I/O bandwidth for these types of files. The command enables management of the association between file inode numbers and extent numbers in the realtime section, facilitating efficient access to realtime data. Without a realtime section, XFS can only store a file in the data section.
CAVEATS
Improper use of `xfs_rtcp` can lead to data corruption or filesystem inconsistencies. It is crucial to understand the structure of the XFS filesystem and the implications of modifying the realtime section before using this command. Backups should always be performed before manipulating the realtime section. This command is mainly useful for very specific and specialized usage, mainly related to audio and video editing where performance is of crucial importance.
REALTIME SECTION CONFIGURATION
The realtime section's size and location are configured during filesystem creation using `mkfs.xfs`. The `mkfs.xfs` command provides options to specify the size of the realtime device. Before you can associate a file with the realtime section using `xfs_rtcp`, you must first have created the filesystem with a realtime section.
HISTORY
The `xfs_rtcp` command has been part of the XFS filesystem toolset since its inception. XFS was designed with features like realtime sections to cater to high-performance I/O requirements, particularly for applications like video editing and streaming. The tool's functionality has been refined over time to improve its reliability and usability, reflecting the ongoing development and support for XFS within the Linux ecosystem.
SEE ALSO
xfs(5), mkfs.xfs(8), xfsdump(8), xfsrestore(8)