Operating System - HP-UX
1832240 Members
2867 Online
110041 Solutions
New Discussion

Re: Interactive/partial ignite restore ?

 
SOLVED
Go to solution
David_246
Trusted Contributor

Interactive/partial ignite restore ?

Hi,

We have done a backup using :
make_tape_recovery -v -A -a /dev/rmt/0mn

Now we want to restore only a couple of files from /dev/vg00 and not the whole vg00. Any ideas how to do this ? Your help will be much apreciated.

Best regs,
David
@yourservice
6 REPLIES 6
RAJESH GANGADHARAN
Regular Advisor
Solution

Re: Interactive/partial ignite restore ?

If you are eable to boot the system from the disk and restore some files you can use the following commands

# mt -t /dev/rmt/0mn fsf 1
# tar -xvf /dev/rmt/0m Filenames.

Hope this will work for you


Regards
Rajesh
Let the choices you make today be the choices you can live with tomorrow.
David_246
Trusted Contributor

Re: Interactive/partial ignite restore ?

Hi Rajesh,

Thanks for your quick reply.

So, let me understand it well.
mt -t fsf 1 ??
- does the one(1) mention an FS or just vg00 ??

Never knew tar would work this way as well. You are very sure it just restores the specified files right ? We are talking about an operational production server. Sorry I have to be carefull.
If this will work out well, both your answers will be a 10-pointer of course !!

P.S. always issue an mt rewind first ?


Best Regs David
@yourservice
James R. Ferguson
Acclaimed Contributor

Re: Interactive/partial ignite restore ?

Hi David:

Yes, the proper command sequence to extract a file from an Ignite recovery tape is:

# mt -t /dev/rmt/0mn fsf 1
# tar -xvf /dev/rmt/0m filename

The 'mt' 'fsf' fowards the tape beyond the LIF area written by Ignite and positions the tape at the tar archive.

It doesn't hurt to rewind the tape before issuing these commands if it is already in the tape drive.

Regards!

...JRF...
RAJESH GANGADHARAN
Regular Advisor

Re: Interactive/partial ignite restore ?

Hi David,

What I understood is that you want to restore some files from the recovery tape (eg: /etc/password, /tcb etc). You can use the command I mentioned eralier for this.

mt -f fsf 1 will point the tape to next count files. not the Volume groups. Make sure that you are using no-rewind device file for this operation. After this command you can issue a tar -tvf command to view the files in the tape. I am always using this command to cross check after creating a tape using make_recovery.

I am sure that all the files are been backed up using tar command only.

before doing tar -xvf do a tar -tvf and confirm the files are there in the tape.

Regards
Rajesh
Let the choices you make today be the choices you can live with tomorrow.
Cheryl Griffin
Honored Contributor

Re: Interactive/partial ignite restore ?

You need to first rewind the tape:
# mt -f /dev/rmt/0mn rew (rewinds)
# mt -f /dev/rmt/0mn fsf 1 (fast forward)
# cd / (change to root)
# tar xvf /dev/rmt/0m etc (restore directory)
Notice no slash is before etc.
OR
# tar xvf /dev/rmt/0m etc/copyright (restore single file)
Again, no slash is before etc.

Cheryl
"Downtime is a Crime."
Andreas Kruth
Occasional Advisor

Re: Interactive/partial ignite restore ?

For reference see also the
manpage of make_tape_recovery(1M):

Section "Extracting files from tape"
After the system recovery
tape has been created, a
single file or files can be
extracted from tape by
seeking to the tape position
where the archive is
located. The mt command can
be used to seek to the
appropriate location, and pax
or tar can be used to extract
files from the archive.

To extract a single file from
the recovery archive:

mt -t /dev/rmt/0mn fsf 1
tar -xvf /dev/rmt/0m filename

Extracting files from tape
can take a long time,
especially when archives are
large.

Regards,

Andreas