Operating System - OpenVMS
1829312 Members
2608 Online
109989 Solutions
New Discussion

Re: Restore one specific file from Tape to Disk

 
SOLVED
Go to solution
Taulant Shamo
Frequent Advisor

Restore one specific file from Tape to Disk

I have created backup for the files in this way:

$ initialize $1$MKA200: A2005
$ mount /foreign $1$MK200:
$ backup SMSC_DATA12:[SMSC_FILES.TRAFFIC_LOG.ARCHIVE_2005]*.*;* -
$1$MKA200:A2005.BCK /label=A2005 /verify
$ dismount /nounload $1$MKA200:

and now I want to restore only the file below:[SMSC_FILES.TRAFFIC_LOG.ARCHIVE_2005]050501_TLG.DMP;2

How can I do that?

Thanks
7 REPLIES 7
Peter Quodling
Trusted Contributor
Solution

Re: Restore one specific file from Tape to Disk

Use the /select=[dir]filename.txt

i.e.

backup $1$MKA200:A2005.BCK/save/select=[SMSC_FILES.TRAFFIC_LOG.ARCHIVE_2005]050501_TLG.DMP;2 *.* (or appropriate destination directory...)

q

Leave the Money on the Fridge.
Taulant Shamo
Frequent Advisor

Re: Restore one specific file from Tape to Disk

Hi Peter,

I give the command that you suggessted 1 hour before and the restore is not finished yet. The file is not large to take so long.

backup $1$MKA200:A2005.BCK/save/select=[SMSC_FILES.TRAFFIC_LOG.ARCHIVE_2005]050501_TLG.DMP;2 -
SMSC_DATA12:[SMSC_FILES.TRAFFIC_LOG.ARCHIVE_2005]

I anything else that could restore quickly?

Thanks
Antoniov.
Honored Contributor

Re: Restore one specific file from Tape to Disk

I'm afraid there is no quicker command.
To restore file, system has to read tape even if it has nothing to restore; when backup meet file selected then restore it.

Antonio Vigliotti
Antonio Maria Vigliotti
Antoniov.
Honored Contributor

Re: Restore one specific file from Tape to Disk

Hi Taulant,
next time you restore some file, use /log qualifier so you know when backup has restored file.

Antonio Vigliotti
Antonio Maria Vigliotti
Volker Halle
Honored Contributor

Re: Restore one specific file from Tape to Disk

Taulant,

BACKUP will read the whole saveset for finding the file, then restore it and continue on reading the saveset until it's end.

As Antonio suggested, using /LOG will tell you, once the file has been restored. You can also type CTRL-T and backup will tell you, if it's restoring the file currently. If you find the restored file on your disk and backup is reporting the following on CTRL-T:

Restoring file: dev:*.*;*
Saveset volume:1, saveset block:XXX (32256 byte blocks)

then you can abort backup. Try CTRL-T a couple of times and if you just see the saveset block number increasing and your file has already been restored, you can safely abort BACKUP.

Depending on your /SELECT specification, BACKUP doesn't know, whether there may be another file matching that specification further down in the saveset, so it has to read until the end of the saveset...

Volker.
Aaron Lewis_1
Frequent Advisor

Re: Restore one specific file from Tape to Disk

Taulant, You may be able to get there faster if you have a complete listing of the tape or a least of good idea of where the file is located.

After mounting the tape drive, you can:

SET MAG $1$MKA200:/SKIP=BLOCK:N
OR
SET MAG $1$MKA200:/SKIP=FILES:N
Taulant Shamo
Frequent Advisor

Re: Restore one specific file from Tape to Disk

Thanks all.