Operating System - HP-UX
1752809 Members
6134 Online
108789 Solutions
New Discussion юеВ

Re: Recovering individual files from Ignite backup

 
Kevin O'Donovan
Regular Advisor

Recovering individual files from Ignite backup

Hi,

if I create an Ignite backup using make_tape_recovery or make_net_recovery, is there anyway to recover a particular, individual file from the archive?

I'm backing up servers which we're returning to the supplier and we want to be able to 'recreate' the server on another machine quickly and easily. I could make an Ignite backup to achieve this but then wouldn't be able to recover individual files if needed, is this right?

thanks in advance, Kevin.
6 REPLIES 6
harry d brown jr
Honored Contributor

Re: Recovering individual files from Ignite backup

TO recover files on an ignite tape do this:

mt -f /dev/rmt/0mn fsf 1
tar -tvf /dev/rmt/0mn

Remember to use the norewind device. On the tar I used the "t" option to display the archive, you can replace the tar options with whatever you need.

live free or die
harry
Live Free or Die
harry d brown jr
Honored Contributor

Re: Recovering individual files from Ignite backup

Kevin,

If you get a like machine, then you can use the make_recovery to build your new system.

Make sure you use the -A and -i options so that you get the entire vg00 onto the tape. The -i option will force an interactive session when/if you boot from the tape. For stuff outside of vg00, use another backup method, like tar or cpio only, for portability reasons!


live free or die
harry
Live Free or Die
Patrick Wallek
Honored Contributor

Re: Recovering individual files from Ignite backup

Also keep in mind that the files in the ignite tar (actually pax) image are stored with path names relative to /.

So if you want restore /etc/passwd then:

# mt -f /dev/rmt/?mn rew
(I always rewind the tape first just be safe)
# mt -f /dev/rmt/?mn fsf 1

# tar -xvf /dev/rmt/?mn etc/passwd

This way if you want to restore /etc/passwd somewhere else then you just make sure you in that directory before you start the tar.

# cd /tmp

# tar -xvf /dev/rmt/?mn etc/passwd

Will restore /etc/passwd from the ignite tape to /tmp/etc/passwd.
Michael Roberts_3
Honored Contributor

Re: Recovering individual files from Ignite backup

Patrick's answer is mostly correct. The example file, /etc/passwd, is one of the exceptions to the relative path rule. /etc/passwd and /etc/group are in the archive
twice. Once as absolute path and once as relative path. This is done so that pax can apply the correct gid and uid to files.

Also it is possible to rename files that you extract from the archive by using pax's interactive option:
pax -rif /dev/rmt/0mn somefile

Will prompt you for what you want to rename 'somefile' when it encounters it in the archive.
etouq ot hguone revelc ton m'i
Sanjay_6
Honored Contributor

Re: Recovering individual files from Ignite backup

Hi Kevin,

you can try this,

cd /
mt -f /dev/rmt/0mn fsf 1
tar xvf /dev/rmt/0m /file_name


If you use the rewind device /dev/rmt/0m in tar command, it will rewind the tape in the drive after finishing the extraction.

Hope this helps.

regds



Tom Danzig
Honored Contributor

Re: Recovering individual files from Ignite backup

All the files in the pax/tar archive are stored relative to root in the form etc/passwd, var/adm/syslog/syslog, etc.

The leading ./ are not present.