Skip to main content

Module replace

Module replace 

Source
Expand description

§Device replacement: replacing a device with another while the filesystem is online

A replace operation copies all data from a source device to a target device, then swaps the target into the filesystem in place of the source. The filesystem remains mounted and usable throughout.

Requires CAP_SYS_ADMIN.

Structs§

ReplaceStatus
Status of a device replace operation, as returned by the status query.

Enums§

ReplaceSource
How to identify the source device for a replace operation.
ReplaceStartError
Result of a replace start attempt that the kernel rejected at the application level (ioctl succeeded but the result field indicates a problem).
ReplaceState
Current state of a device replace operation.

Functions§

replace_cancel
Cancel a running device replace operation on the filesystem referred to by fd.
replace_start
Start a device replace operation, copying all data from source to the target device at tgtdev_path.
replace_status
Query the status of a device replace operation on the filesystem referred to by fd.