09-17-2015 07:00 AM
Hello,
I need to restore a folder and its contents from one server to another (located on the same master server) can anyone help with the correct syntax? Below is the information.
Note: both are Windows client Servers
Restore from 8/24/2015 to 9/17/2015 (8/24/15 was the last full backup so I want to start from there up to current date)
Spj200.xa.meta.xx.xx to lm-pagex1-f3-e.xxx.xxxx.01
source server is spj200 (see above) Source folder is located on the G:\mjfage\_upload\
Destination (lm-patex1-f3-e.xxx.xxxx.01) E:HPC_stage\_upload\
In the meantime I will try to look for any syntax I can find in the manuals.
Fyi - I have not done a command line restore yet always used the GUI Console. In this case for some reason we can't open the folder on the source server it just gives us a hour glass.
Master Server is Linux running 7.6.0.3
Clients are both Windows servers running client 7.6.0.3
Best Regards
Solved! Go to Solution.
09-17-2015 07:21 AM
Specifies a destination client. The default is the current client name.
On UNIX systems, the master server root user can use this option to do the following: Direct restored files to a computer other than the client that the -C option specifies.
On Windows systems, the master server administrator can use this option to do the following: Direct restored files to a computer other than the client that the -C option specifies.
For different client:
>bprestore -B -L <progress log> -C <sourceClient> -D <destinationClient> -R <RenameFileList> -f <RestoreFileList>
09-17-2015 07:52 AM
In addition to above excellent info, add '-s' for start date. Without -e (end-date) the current date will automatically be selected.
-s 8/24/2015
Create bprd log folder on the master server if it does not exist already.
Restart NBU on master to enable this log.
Other log folders:
On media server: bptm and bpbrm (no restart needed)
On destination client: bpcd and tar (no restart needed)
Since you are having a problem with browsing in BAR GUI, you may want to check if bplist is working.
On master:
bplist -C <source client> -s 8/24/2015 -R 4 /G/mjfage/_upload
09-17-2015 08:14 AM
Specifies a file (listfile) that contains a list of files to be restored and can be used instead of the filenames option. In listfile, list each file path must be on a separate line.
The required format for the file list depends on whether the files have spaces or newlines in the names.
To restore the files that do not have spaces or new lines in the names, use this format:
filepath
Where filepath is the path to the file that you restore. For example:
Note: |
For Windows systems, use upper case for the drive letter. For example, |
UNIX systems:
/home /etc /var
Windows systems:
C:\programs C:\winnt C:\documents\old_memos
To restore the files that have spaces or new lines in the names, use one of the following formats:
filepathlen filepath filepathlen filepath start_date_time end_date_time filepathlen filepath -s datetime -e datetime
The filepath is the path to the file you restore.
The filepathlen is the total number of characters in the file path.
The start_date_time and end_date_time are the decimal number of seconds since 01/01/1970 00:00:00.
datetime is the same as the command line (mm/dd/yy [hh[:mm[:ss]]]). The command uses the start date, end date, and time from the command line unless a line in listfile overrides it. The dates may change from line to line.
The required date and time values format in NetBackup commands varies according to your locale. The /usr/openv/msg/.conf
file (UNIX) and the install_path\VERITAS\msg\LC.CONF
file (Windows) contain information such as the date-time formats for each supported locale. The files contain specific instructions on how to add or modify the list of supported locales and formats.
See "About specifying the locale of the NetBackup installation" in the NetBackup Administrator's Guide, Volume II.
To exclude a file or a directory path that was previously included in the restore, place an exclamation mark (!) in front of the file or the directory path. This exclude option is not supported by NDMP restores and FlashBackup.
The following is an example that uses filepathlen filepath:
UNIX systems:
5 /home 4 /etc 4 /var 19 /home/abc/test file 12 !/etc/passwd
Windows systems:
11 C:\programs 8 C:\winnt 22 C:\documents\old memos 17 !C:\programs\test -f filenames
Names one or more files to be restored and can be used instead of the -f option.
Any files that you specify must be listed at the end of the command line after all other options. You must use absolute file paths.
To exclude a file or a directory path that was previously included in the restore, place an exclamation mark (!) in front of the file or the directory pat. Exceptions: NDMP restores.
For Windows systems, use upper case for the drive letter. For example, C:\NetBackup\log1
.
09-17-2015 07:16 AM
by default, you can not start an alternate client restore from a client.
use your masters server GUI to start the restore by selecting the source and destination clients
if you need to start the restore from the client create the following file at your master server and retry
UNIX: /usr/openv/netbackup/db/altnames/No.Restrictions
Windows: install_path\NetBackup\db\altnames\No.Restrictions
If you can, avoid the command line restore.
09-17-2015 07:21 AM
Specifies a destination client. The default is the current client name.
On UNIX systems, the master server root user can use this option to do the following: Direct restored files to a computer other than the client that the -C option specifies.
On Windows systems, the master server administrator can use this option to do the following: Direct restored files to a computer other than the client that the -C option specifies.
For different client:
>bprestore -B -L <progress log> -C <sourceClient> -D <destinationClient> -R <RenameFileList> -f <RestoreFileList>
09-17-2015 07:27 AM
hello Ignacio, I'm glad to hear you again .
09-17-2015 07:40 AM
Me too Stefanos!
09-17-2015 07:49 AM
Hi StefanosM and Pedro,Thank you for your quick responses,
Stefanos Thank you, believe me up until this point I have avoid using the command line restore. However for some reason we can't get the folder to open using the Gui it just clocks (hour glass) and it sits there for hours and we are not sure why. And its just that one folder we need to restore every other folder on the client opens fine.
Pedro thanks,
so in my case it would be
For different client:
>bprestore -B -L <progress log> -C <sourceClient> -D <destinationClient> -R <RenameFileList> -f <RestoreFileList>
bprestore -B -L progress log -C Spj200.xa.meta.xx.xx -D lm-pagex1-f3-e.xxx.xxxx.01 -R G:\mjfage\_upload\ -f E:HPC_stage\_upload\
What about the Dates I want the folder (and contents from 8/24/2015 to 9/17/2015)
Also what are these parameters ? >> RenameFileList> -f <RestoreFileList>
Thanks, I just want to make sure the syntax is correct before I try it.
This is done on the Master Server correct from /usr/openv/netbackup/bin
Best Regards
09-17-2015 07:52 AM
In addition to above excellent info, add '-s' for start date. Without -e (end-date) the current date will automatically be selected.
-s 8/24/2015
Create bprd log folder on the master server if it does not exist already.
Restart NBU on master to enable this log.
Other log folders:
On media server: bptm and bpbrm (no restart needed)
On destination client: bpcd and tar (no restart needed)
Since you are having a problem with browsing in BAR GUI, you may want to check if bplist is working.
On master:
bplist -C <source client> -s 8/24/2015 -R 4 /G/mjfage/_upload
09-17-2015 08:14 AM
Specifies a file (listfile) that contains a list of files to be restored and can be used instead of the filenames option. In listfile, list each file path must be on a separate line.
The required format for the file list depends on whether the files have spaces or newlines in the names.
To restore the files that do not have spaces or new lines in the names, use this format:
filepath
Where filepath is the path to the file that you restore. For example:
Note: |
For Windows systems, use upper case for the drive letter. For example, |
UNIX systems:
/home /etc /var
Windows systems:
C:\programs C:\winnt C:\documents\old_memos
To restore the files that have spaces or new lines in the names, use one of the following formats:
filepathlen filepath filepathlen filepath start_date_time end_date_time filepathlen filepath -s datetime -e datetime
The filepath is the path to the file you restore.
The filepathlen is the total number of characters in the file path.
The start_date_time and end_date_time are the decimal number of seconds since 01/01/1970 00:00:00.
datetime is the same as the command line (mm/dd/yy [hh[:mm[:ss]]]). The command uses the start date, end date, and time from the command line unless a line in listfile overrides it. The dates may change from line to line.
The required date and time values format in NetBackup commands varies according to your locale. The /usr/openv/msg/.conf
file (UNIX) and the install_path\VERITAS\msg\LC.CONF
file (Windows) contain information such as the date-time formats for each supported locale. The files contain specific instructions on how to add or modify the list of supported locales and formats.
See "About specifying the locale of the NetBackup installation" in the NetBackup Administrator's Guide, Volume II.
To exclude a file or a directory path that was previously included in the restore, place an exclamation mark (!) in front of the file or the directory path. This exclude option is not supported by NDMP restores and FlashBackup.
The following is an example that uses filepathlen filepath:
UNIX systems:
5 /home 4 /etc 4 /var 19 /home/abc/test file 12 !/etc/passwd
Windows systems:
11 C:\programs 8 C:\winnt 22 C:\documents\old memos 17 !C:\programs\test -f filenames
Names one or more files to be restored and can be used instead of the -f option.
Any files that you specify must be listed at the end of the command line after all other options. You must use absolute file paths.
To exclude a file or a directory path that was previously included in the restore, place an exclamation mark (!) in front of the file or the directory pat. Exceptions: NDMP restores.
For Windows systems, use upper case for the drive letter. For example, C:\NetBackup\log1
.
09-17-2015 08:25 AM
Hi Marianne, Thank you for your response also.
Does it matter where in the syntax this start date >> -s 8/24/2015 should be placed?
for example
bprestore -s 8/24/2015 - B -L progress log -C Spj200.xa.meta.xx.xx -D lm-pagex1-f3-e.xxx.xxxx.01 -R G:\mjfage\_upload\ -f E:HPC_stage\_upload\
Thanks again
09-17-2015 10:18 AM
Pedro Thanks,
Yes I don't think I will need this >> -R is for rename the path however –f I believe I will need to use. I will look in the manual.
regards
09-18-2015 12:39 AM
Great nbustarter380, let us know the result.