Date: Sun, 3 Jun 2018 00:42:36 +0000 (UTC) From: Rick Macklem <rmacklem@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r334548 - projects/pnfs-planb-server/usr.bin/pnfsdscopymr Message-ID: <201806030042.w530gamN004669@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rmacklem Date: Sun Jun 3 00:42:36 2018 New Revision: 334548 URL: https://svnweb.freebsd.org/changeset/base/334548 Log: Update the pnfsdscopymr man page for recent changes related to the change to the distributed mirror model. Modified: projects/pnfs-planb-server/usr.bin/pnfsdscopymr/pnfsdscopymr.1 Modified: projects/pnfs-planb-server/usr.bin/pnfsdscopymr/pnfsdscopymr.1 ============================================================================== --- projects/pnfs-planb-server/usr.bin/pnfsdscopymr/pnfsdscopymr.1 Sat Jun 2 22:40:16 2018 (r334547) +++ projects/pnfs-planb-server/usr.bin/pnfsdscopymr/pnfsdscopymr.1 Sun Jun 3 00:42:36 2018 (r334548) @@ -24,65 +24,66 @@ .\" .\" $FreeBSD$ .\" -.Dd March 9, 2018 +.Dd June 2, 2018 .Dt PNFSDSCOPYMR 1 .Os .Sh NAME .Nm pnfsdscopymr .Nd -makes a copy of a file's data on a recovered/new mirror data storage server (DS) +copy or move a data storage file for a MDS file to a different DS .Sh SYNOPSIS .Nm -.Ar file -.Ar mounted_on_path_of_recovered_DS -.Ar mounted_on_path_of_operational_DS +.Op Fl r Ar mounted-on-DS-dir +.Op Fl m Ar source-mounted-on-DS-dir destination-mounted-on-DS-dir +.Ar mdsfile .Sh DESCRIPTION The .Nm -command copies a file's data from a operational DS to a recovered (or new) -DS that is configured as a mirror of this operational DS. -If the recovered/new DS is configured as a mirror of the operational DS, the -data of the -.Ar file -on the MDS -is copied to the recovered DS, unless the recovered/new DS -already has a valid copy. -The copy is considered valid if it exists in the extended attribute of the -MDS file and its IP address is non-zero. -If the -.Ar file -does not have the operational DS in its extended attribute or it already -has a valid copy of the file's data, the command simply does an exit(0). -This is done so that the command can be called on any file within the MDS's -exported file tree safely. +command copies a data storage file for an MDS file from one DS to another DS. +It is normally used to recover data files onto a repaired DS, but can also +be used to manually migrate a data storage file from one DS to a different one. +By default, the command will copy the data storage file for +``mdsfile'' +to one of the other DSs to create a mirror of it. +This might be done if the file was created before mirroring was enabled on +the pNFS service and now needs to be mirrored. .Pp -The first argument -.Ar file -is the file on the MDS, the second argument -.Ar mounted_on_path_of_recovered_DS -is the mounted on directory path of the recovered/new mirror and -the third argument -.Ar mounted_on_path_of_operational_DS -is the mounted on directory path of a non-disabled DS that is a mirror of the -recovered/new DS. -The third argument is used to check if the -.Ar file -argument is stored on the mirror set that includes the recovered/new DS -so that it can be used within a -.Xr find 1 . +The following options are available: +.Bl -tag -width Ds +.It Fl r Ar mounted-on-DS-dir +This option indicates that the data storage file should be created on the DS +that is mounted on the directory ``mounted-on-DS-dir''. +It will only do the copy if there is an entry in the pnfsd.dsfile extended +attribute that has an IP address of 0.0.0.0. +See +.Xr pnfsdsfile 1 +for how to do this. +This is normally done for all regular files via +.Xr find 1 +in order to recover the data +storage files onto a repaired DS. +.It Fl m Ar source-mounted-on-DS-dir destination-mounted-on-DS-dir +This option indicates that the data storage file is to be migrated from +the source DS mounted on the diectory ``source-mounted-on-DS-dir'' to +the DS mounted on the directory ``destination-mounted-on-DS-dir''. +In this case, the data storage file will be removed from the source DS +when the copy is completed. +.El +If the copy/migration is already done, the command will simply exit(0), +so that it can safely be used on all regular files in the exported directory +tree on the MDS. .Pp This command must be run on the MDS and a typical usage would be as an argument for .Xr find 1 for all regular files. .sp -For example, if the recovered/new DS is mounted on /data3 and it is a -mirror of the DS mounted on /data2: +For example, if the repaired DS is mounted on /data3 and files previously +stored on the repaired DS have had the DS's IP address set to 0.0.0.0: .br # cd <top-level-exported-directory-on-the-MDS> .br -# find . -type f -exec pnfsdscopymr {} /data3 /data2 \\; -.El +# find . -type f -exec pnfsdscopymr -r /data3 {} \\; .Sh SEE ALSO .Xr find 1 , .Xr pnfsdsfile 1 ,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806030042.w530gamN004669>