Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MKSYSB

Status
Not open for further replies.

harpal

Technical User
Oct 3, 2001
115
GB
Hi,

I am trying to restore a specific file from a mksysb backup what is the command to restore the following file plz

./home/hsingh/t020506.log

thanks in advance

Harpal
 
Harpal

I've cut & pasted some info from some hints & tips we have at my site:

The following is a description of mksysb's four images.


+--------------------------------------------------------------------------------+
| Bosboot | Mkinsttape | Dummy TOC | rootvg |
| Image | Image | Image | data |
|---------------+------------------+----------------------+---------------------|
|<--------------- Block size 512 ---------------> | Blksz defined |
| | by the device.|
+---------------------------------------------------------+---------------------+


So, in order to get to the rootvg data we need to skip the first three images. First of all however we need to find out what block size was used to create the data back up image. This is done by the following procedure:


To obtain the blocksize of the fourth image enter:

cd /tmp
tctl -f /dev/rmt# rewind (# to be replaced by a number)
chdev -l rmt# -a block_size=512
restore -s2 -xqdvf /dev/rmt#.1 ./tapeblksz
cat ./tapeblksz


The output given will be the blocksize the tape drive was set to when the mksysb was made. We can now continue with the

actual restoration of the data:


The blocksize of the tape drive needs to be set accordingly, by entering:

chdev -l rmt# -a block_size=[number in the ./tapeblksz file]


The files or directories need to be restored by entering:

cd / (if the file is to be restored to its original place or cd /xxx/yyy if the file is to be restored somewhere else)

tctl -f /dev/rmt# rewind
restore -s4 -xqvf /dev/rmt#.1 ./dir/filename (for one file - you must include the '.' before the filename)


or


restore -s4 xqdvf /dev/rmt#.1 ./dir (for all files in the directory)


To list the files on the mksysb do:

restore -s4 -Tqvf /dev/rmt0.1


HTH
Mark

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top