How to restore a single file from tape backup to a specific directory in AIX 6.1
AIXThis forum is for the discussion of IBM AIX.
eserver and other IBM related questions are also on topic.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Red Hat, Fedora, SuSe, HPUX, Solaris
Posts: 12
Rep:
How to restore a single file from tape backup to a specific directory in AIX 6.1
Hi All,
I've inherited an AIX 6.1 box and I have to restore a single file from a tape device. The hardware is on another country and I don't have physical access to it - just remote access via putty.
So far I can see multiple rmt0 devices under /dev/ (rmt0, rmt0., rmt0.1, rmt0.2,.... rmt0.6)
Also, to list the files on the tape, I had to do
Code:
dd if=/dev/rmt0 bs=128k | tar tvf -
. Commands like
Code:
restore -Tvf /dev/rmt0
just run into
Code:
"restore: 0511-260 the archive is not in backup format"
errors
With that said, I tried to run
Code:
smit restfile
, but I just get the same
Code:
"restore: 0511-260 the archive is not in backup format"
error.
So, how should I proceed to restore a single file from that tape into a destination directory defined by myself?
Step 1 is to look at the tape backup scripts (I assume there are scripts) and discover how the tape is WRITTEN. Until you know what was written, trying to extract randomly is pointless. IF you were to succeed, it would be a product of impure luck. I hate depending upon luck! Start from certain knowledge.
There is no such script under root user as well as other users
Then there should be some kind of continuity document, procedure manual, DR manual, or other documentation that records how backup and recovery was intended to work on this platform. (All assuming the System Admin knew his job.) You need to know how the backups were written to be sure you can recover them. You can test them with some of the common tools (tar or pax for example) but until you know the details on format and the command line options used you are shooting in the dark.
PS. I have, on occasion, solved issue when shooting in the dark. I HATE that. It is always better to know what SHOULD work so you can better identify causes when it does NOT. Without that, if it works you will not know why it worked, if it fails you will not know why it failed. That is a poor way to start off.
PPS. Could this be a Makesysb or Savevg tape rather than a regular backup tape? That would make a HUGE difference! There are man, info, DOC, and Redbook pages for those utilities available for install and online at the IBM support sites.
You are having all kinds of trouble separating out an individual file off the tape. I suggest that you try restoring the entire tape to a hard drive and then look for the file that you want on the hard drive.
You are having all kinds of trouble separating out an individual file off the tape. I suggest that you try restoring the entire tape to a hard drive and then look for the file that you want on the hard drive.
------------------------------
Steve Stites
While that should work, it assumes you have adequate storage space for that size of a restore. If you do, that costs only time. If not, I believe you have pointers to the kinds of places to look up information. Please let us know what you find.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.