Operating System - HP-UX
1833772 Members
2749 Online
110063 Solutions
New Discussion

Viewing contents of Ignite tape...

 
SOLVED
Go to solution
Jim Allan
Advisor

Viewing contents of Ignite tape...

All,

I want to restore ONE directory that was backed up during a full system Ignite backup.
I've never used ignite before (set up by previous sysadmin) and don't want to wipe the tape or accidently restore the entire OS!

Thanks in advance

Jimmy,

Perth WA
10 REPLIES 10
Jeroen Peereboom
Honored Contributor
Solution

Re: Viewing contents of Ignite tape...

Jim,

an Ignite tape contains two 'archives'.
The first is bootable, the second a tar-archive.

You need to position the tape just before the tar-archive and next give the tar-extract command (using a no-rewind device).

mt -t /dev/rmt/0mn fsf 1

tar xvf /dev/rmt/0mn ''

If you are using wildcards in do not forget the apostrophes (to prevent the shell from doing filename expansion). You may want to start with tar tvf '' to check the contents of the tape.

JP.
twang
Honored Contributor

Re: Viewing contents of Ignite tape...

On a working computer run:
mt -f TAPE_NAME rew
mt -f TAPE_NAME_NO_REWIND fsf 1
tar tvf TAPE_NAME

If the tape is OK, you will see a list of backed up files.
To recover a particular FILE:
tar xvf TAPE_NAME /path/filename (will only recover full path)

Note:
TAPE_NAME=/dev/rmt/0m
TAPE_NAME_NO_REWIND=/dev/rmt/0mn
Sridhar Bhaskarla
Honored Contributor

Re: Viewing contents of Ignite tape...

Hi Jimmy,

Ignite tape is not intended for selective recoveries. It's not a good idea to make a full backup of the system using ignite. It's better if ignite is limited only to vg00 filesystems. Rest can be easily imported.

Having said that, it is possible to recover the selected files/directories from the tape. The tape is basically written in two parts. 1- bootarea and 2-archive. You will need to forward the tape past bootarea and extract the archive. Try the following commands.

#cd /some_staging_area
#mt -t /dev/rmt/0m rew
#mt -t /dev/rmt/0mn fsf 1
#tar xvf /dev/rmt/0mn apps/your_directory

Look at the no-rewind device in last two steps.

Note that you have specify full path to your directory without the first '/' as ignite backs up the contents relative to /.

These steps are illustrated in make_tape_recovery man page. It can be a painfully waiting process. Since you are handling it first time, I suggest you recover it on a test system. You can always copy the content over the network once it is recovered.

I suggest you take 'fbackup' of OS along with make_tape_recovery so that you can easily recover the files in case needed.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Ranjith_5
Honored Contributor

Re: Viewing contents of Ignite tape...

Hi Jim,

Which directory you want to restore. Do u have a habit of taking a normal root backup ? In that case you can restore from that.

You can try a check_recovery.

This will update your old tape. After that you can do a full recovery with the same tape.

Take a full system backup before you proceed with any kind of ignite restore as a safe step.

regards,
Syam
Jim Allan
Advisor

Re: Viewing contents of Ignite tape...

the directory is /home/

i just want to tar txf it i guess, because i want to see the permissions (permissions got messed up on the systems /home).

however, when i type

tar tvf /dev/rmt/0mn "/home"

it begins to list the entire contents of the tape.. how do i get it to just list /home?
Sridhar Bhaskarla
Honored Contributor

Re: Viewing contents of Ignite tape...

Hi,

Take the first / out and specify it as just home.

tar tvf /dev/rmt/0mn home

Ignite backs up the contents relative to /, like usr/bin, etc/lvmconf etc.,

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Jim Allan
Advisor

Re: Viewing contents of Ignite tape...

Hi, this didn't work for me


[root@*******]# tar tvf /dev/rmt/0mn home
r-xr-xr-x 2/2 0 Dec 10 16:29 2003 stand/
rwxr-xr-x 0/0 0 May 17 13:22 2002 stand/lost+found/
rw-r--r-- 0/1 1639 Dec 10 16:09 2003 stand/system
r--r--r-- 0/3 82 Nov 16 03:04 2000 stand/kernrel
rw-r--r-- 0/3 3336 Dec 10 16:29 2003 stand/ioconfig
rw-r--r-- 0/3 19 May 17 13:28 2002 stand/bootconf
rw------- 0/3 0 May 17 13:43 2002 stand/.kminstall_lock
rwxr-xr-x 0/3 0 May 17 13:52 2002 stand/system.d/
rw-r--r-- 0/3 174 May 17 13:52 2002 stand/system.d/krm
rwxr-xr-x 0/3 0 Dec 10 16:14 2003 stand/build/
rw-r--r-- 0/3 95658 Dec 10 16:13 2003 stand/build/conf.c
rwxr--r-- 0/3 11567 Dec 10 16:13 2003

etc etc

at the moment i am running it, grepping for home, and piping it to a file for reference.. just hoping there is a better (more efficient) way..
twang
Honored Contributor

Re: Viewing contents of Ignite tape...

tar tvf /dev/rmt/0m
is for listing the content of the tar's part, to selectively recover, you should issue the following command:
tar xvf /dev/rmt/0m /path/filename
remember this will only recover full path.
Jim Allan
Advisor

Re: Viewing contents of Ignite tape...

thanks guys,
everything ran ok, tar tvf gave the permissions listing for the files i was looking for, but not the ownership.

restoring has been done and ownership compared. thanks for your help

cheers
Jim Allan
Advisor

Re: Viewing contents of Ignite tape...

The solution to my problem of viewing the contents of a Ignite based back up file is as below

tar tvf /dev/rmt/0mn >> output


Thanks to all