LFS-MIRROR-RESYNC(1)

NAME
lfs-mirror-resync - resynchronize an out-of-sync mirrored file

SYNOPSIS
lfs mirror resync [--only MIRROR_ID[,...]] [--bandwidth=|-W BANDWIDTH_MB] [--force-resync|-f] [--stats] [--stats-interval= INTERVAL_SECONDS] MIRRORED_FILE [MIRRORED_FILE2 ...]

DESCRIPTION
This command resynchronizes out-of-sync mirrored file(s) specified by the path name MIRRORED_FILE.

If there is no stale mirror for the MIRRORED_FILE(s), then the command does nothing. If mirrors are inconsistent but no components are marked as stale, the command will fail with an error message suggesting the use of --force-resync. Otherwise, it will copy data from synced mirror to stale mirror(s), and mark all successfully copied mirror(s) as SYNC.

If --only option is not specified, the nosync mirror(s) (i.e. components that have this flag set) will not be synced.

If --only MIRROR_ID[,...] option is specified, then the command will resynchronize the mirror(s) specified by the IR MIRROR_ID (s), even nosync mirror(s) will be resynchronized as well. This option cannot be used when multiple mirrored files are specified.

OPTIONS

--only MIRROR_ID[,...]
    This option indicates which mirror(s) specified by MIRROR_ID(s) needs to be resynchronized. The MIRROR_ID is the numerical unique identifier for a mirror. Multiple MIRROR_IDs are separated by comma. This option cannot be used when multiple mirrored files are specified.

-f, --force-resync
    Force resynchronization of specified mirrors even when they are not marked as stale. This option requires the --only option to specify which mirrors to resync. When mirrors are inconsistent but no components are marked as stale, normal resync will fail with an error message suggesting the use of this option.

--stats
    This option enables progress updates every 5 seconds, in YAML format.

--stats-interval=STATS_INTERVAL
    This option enables progress updates every STATS_INTERVAL seconds, in YAML format.

-W, --bandwidth BANDWIDTH_MB[MG]
    Limit the read and write bandwidth a mirror resync consumes to no more than BANDWIDTH_MB MiB/s. An optional suffix can be used to specify units in Megabytes or Gigabytes per second.

EXAMPLES
Resynchronize all of the stale and sync-able mirror(s) for /mnt/lustre/file1 and /mnt/lustre/file2:
        # lfs mirror resync /mnt/lustre/file1 /mnt/lustre/file2

Resynchronize mirrors with mirror ID 4 and 5 for /mnt/lustre/file1 even if they are not marked as STALE:
        # lfs mirror resync --only 4,5 /mnt/lustre/file1

Force resynchronization of mirror 2 when mirrors are inconsistent but not marked as stale:
        # lfs mirror resync --only 2 --force-resync /mnt/lustre/file1

AVAILABILITY
The lfs mirror resync command is part of the lustre(7) filesystem package since release 2.11.0

SEE ALSO
lfs(1), lfs-mirror-create(1), lfs-mirror-extend(1), lfs-mirror-split(1), lfs-mirror-verify(1), lfs-setstripe(1)