Manual Chapter :
Restoring a Volumes Files
Applies To:
Show VersionsARX
- 6.3.0
You can back up client files by working around a managed volume and connecting directly to its back-end filers. Backups are read operations, so they cannot create inconsistencies in a volumes metadata. This can follow the same workflow that was used before the introduction of the ARX. For example, you might use NDMP on a data-protection device (called a backup server in this manual) to keep file-server backups:
Appendix 3, Tracking Files on Your Back-End Storage, explained how to find back-end file locations at any given time. This chapter explains some methods for restoring them to an ARX service.
You can use the output from show file-history virtual-service or find to retrieve files from your backup server. For example, consider the following command which shows the location of the a_adams.dat file as of the last series of backups (September 14 in this example):
bstnA# show file-history virtual-service ac1.medarch.org ARCHIVES date 09/14/2009 file a_adams.dat path /2005/planA
bstnA# ...
You can use the find command to locate the same file as of now. This shows that the file migrated to the filer at 192.168.25.27 since September 14:
bstnA# find global-server ac1.medarch.org cifs ARCHIVES path /2005/planA/a_adams.dat
bstnA# ...
Using the earlier date and filer path, you can recover the file from your backup server. From the examples above, the file was on fs1 on September 14, when backups occurred. At the backup server, we recover the file from the September-14 backup of fs1. We suggest placing the recovered file back onto the original filer (fs1), but outside any imported directory. This side directory acts as a staging area for restored files.
Important: If the staging-area directory is inside any imported tree, this restore operation causes an inconsistency between the filer state and the metadata in a managed volume. We strongly advise that you choose a staging area that is not imported by any managed volume.
A restore operation automatically copies a restored file from the staging area to its managed volume, which then places the file into the share where it currently resides:
Before you use the restore data command (described below), you need to identify the file server with the staging-area directory. This is the source for the ARX-restore operation. In most cases, the staging area is on the same filer where the file originally resided, in a directory outside of any imported share. In this case, the external-filer configuration already exists to support the imported share(s), and you can skip to the next section.
For cases where the staging area is on a filer that is currently unused by the ARX, configure it as an external filer. (For detailed instructions on this, refer to Appendix 6, Adding an External Filer in the ARX® CLI Storage-Management Guide.)
bstnA(gbl)# external-filer nasE1
bstnA(gbl-filer[nasE1])# ip address 192.168.25.51
The restore data command invokes the restore operation:
restore data namespace volume vol path dest-path
filer src-filer {nfs export | cifs share}+ source-path src-path
[recurse] [remove-source]
filer src-filer {nfs export | cifs share}+ source-path src-path
[recurse] [remove-source]
namespace is 1-30 characters. Use the namespace from the show file-history virtual-service or find output, shown earlier. |
vol is 1-1024 characters. Type ? for a list of volumes in the above namespace, and choose the volume behind the clients front-end share. If you cannot find the complete path you need (such as /claims/stats), choose the volume that is the root of your path (/claims). |
dest-path is also 1-1024 characters. This could be the remainder of the path you started with the vol, above (for example, /stats). The restore process creates a /restore directory below this path, and places the restored file(s) in there. |
filer src-filer {nfs export | cifs share}+ source-path src-path points to the filer with the staging area and the backup file(s):
src-filer (1-64 characters) is the external-filer name for the filer with the staging area, |
cifs share (1-1024 characters) identifies the CIFS share. For a multi-protocol share, enter both paths: nfs export cifs share. |
src-path (1-1024 characters) is the path to the backup file(s). This is the staging-area directory. |
recurse (optional) causes the restore operation to descend into subdirectories. |
remove-source (optional) activates a clean-up routine after the restore is finished; the restore operation removes the backup files after confirming a successful restore to the volume. |
Every restore operation produces a report as it runs. The CLI shows the report name after you invoke the command. Use show reports for a full list of restore reports, and use show, tail, or grep to view one report. The report shows the progress of the operation.
bstnA(gbl)# end
bstnA# restore data insur volume /claims path stats filer nasE1 nfs /root_vdm_4/backups cifs BACKUPS source-path /stats recurse
bstnA# ...
bstnA# show reports restore.7._claims.rpt
bstnA# ...
From any remote host that supports the Secure SHell (SSH) protocol, you can run the restore data command and see the report. Use the following syntax with ssh:
admin-user is the username for a valid administrative account at the ARX (use show users to list all of them, as shown in Listing All Administrative Users, on page 2-14 of the ARX® CLI Network-Management Guide),
mip is a management-IP address for the ARX (use show interface mgmt to show the out-of-band management interface, or show interface vlan to show all in-band management interfaces), and
restore data... is the full restore data command, described above. Surround this with quotation marks ().
For example, the following command sequence re-runs the above restore data command from a remote machine, mgmt17.
juser@mgmt17:~$ ssh admin@10.1.1.7 restore data insur volume /claims path stats filer nasE1 nfs /root_vdm_4/backups cifs BACKUPS source-path /stats recurse
juser@mgmt17:~$ ssh admin@10.1.1.7 show reports restore.9._claims.rpt
A restore operation occurs in the background while you can run other CLI commands or GUI functions. To see the high-level status of all restore operations, use the show restore data command:
bstnA(gbl)# show restore data
bstnA(gbl)# ...
namespace (1-30 characters) selects a namespace,
vol-path (1-1024 characters) narrows the scope to a specific volume, and.
path (1-1024 characters) narrows the scope further, to a specific virtual path in the volume (for example, /home/jrandom). This is relative to the vol-path.
bstnA(gbl)# show restore data insur volume /claims path /stats
bstnA(gbl)# ...
The show restore data command displays a running history of all restore operations. The history goes back indefinitely, so the command can display a very large number of records over time. You can clear all of these records at once, or all records for a particular namespace, volume, or path. From priv-exec mode, use the clear restore data command:
namespace (optional, 1-30 characters) identifies one namespace with restore records. If this option is omitted, the command clears all restore-operation records from the history.
vol-path (optional, 1-1024 characters) narrows the scope to one volume, and
path (optional, 1-1024 characters) narrows the scope further to a specific virtual path. This is relative to the vol-path.
Before clearing the records, a prompt requests confirmation; enter yes to confirm. After you clear the records, they no longer appear in the show restore data output.
This only affects completed restore operations. It does not affect any restore operation that is in-process when you run the clear command.
bstnA(gbl)# show restore data
bstnA(gbl)# end
bstnA# clear restore data
bstnA# show restore data
bstnA# ...
To cancel an in-progress restore operation, go to priv-exec mode and use the cancel restore data command:
namespace (1-30 characters) identifies the namespace,
vol-path (1-1024 characters) is the volume, and
path (1-1024 characters) is the specific virtual path that is being restored. This is relative to the vol-path.
A prompt requests confirmation before the CLI cancels the restore; enter yes to confirm that you want to cancel the operation.
bstnA(gbl)# end
bstnA# cancel restore data wwmed volume /acct path /
bstnA# ...