How to Restore a mksysb without Preserving Mirrors


Contents

About This Document
    Related Documentation
Creating a mksysb without Mirroring
Breaking Mirrors on an Existing mksysb

About This Document

This document describes how to restore a mksysb image without preserving mirrors. Information in this document is valid for AIX Versions 4.x only.

WARNING: This procedure is valid ONLY with a mksysb image and will NOT work with a SYSBACK 6000 system backup.

Related Documentation

The AIX and RS/6000 product documentation library is also available:

http://www.rs6000.ibm.com/resource/


Creating a mksysb without Mirroring

If the ability to rerun the mksysb is available, the following procedure will allow you to create a mksysb without preserving mirroring.
  1. To create a new image.data file, run the following command:
  2.        mkszfile
  3. Change directories to / and vi the image.data file.
  4.        cd / 
           vi image.data
  5. The following examples show an lv_data stanza of an image.data file. The first example is with mirroring, while the second example shows the edited version without mirroring. The lines that need changes are marked by --> and are boldfaced. In the second example, the changes are made to those lines.
  6. To view and edit the file, execute:

     
               vi  image.data 
    
    Example 1
     
                       lv_data: 
                               VOLUME_GROUP= rootvg 
                               LV_SOURCE_DISK_LIST=  hdisk0 
                               LV_IDENTIFIER= 00000001113f3c62.5  
                               LOGICAL_VOLUME= hd2 
                               VG_STAT= active/complete 
                               TYPE= jfs 
                               MAX_LPS= 512 
                      -->      COPIES = 2  
                               LPs = 70  
                               STALE_PPs= 0 
                               INTER_POLICY= minimum 
                               INTRA_POLICY= center 
                               MOUNT_POINT= /usr 
                               MIRROR_WRITE_CONSISTENCY= on 
                               LV_SEPARATE_PV= yes 
                               PERMISSION= read/write 
                               LV_STATE= opened/syncd 
                               WRITE_VERIFY= off 
                               PP_SIZE= 4 
                               SCHED_POLICY= parallel 
                      -->      PP = 140  
                               BB_POLICY= relocatable 
                               RELOCATABLE= yes 
                               UPPER_BOUND= 32 
                               LABEL= /usr 
                               MAPFILE= 
                               LV_MIN_LPS= 68 
    

    Example 2

     
                       lv_data: 
                               VOLUME_GROUP= rootvg 
                               LV_SOURCE_DISK_LIST=  hdisk0 
                               LV_IDENTIFIER= 00000001113f3c62.5 
                               LOGICAL_VOLUME= hd2 
                               VG_STAT= active/complete 
                               TYPE= jfs 
                               MAX_LPS= 512 
                      -->      COPIES = 1 
                               LPs = 70  
                               STALE_PPs= 0 
                               INTER_POLICY= minimum 
                               INTRA_POLICY= center 
                               MOUNT_POINT= /usr 
                               MIRROR_WRITE_CONSISTENCY= on 
                               LV_SEPARATE_PV= yes 
                               PERMISSION= read/write 
                               LV_STATE= opened/syncd 
                               WRITE_VERIFY= off 
                               PP_SIZE= 4 
                               SCHED_POLICY= parallel 
                       -->     PP = 70 
                               BB_POLICY= relocatable 
                               RELOCATABLE= yes 
                               UPPER_BOUND= 32 
                               LABEL= /usr 
                               MAPFILE= 
                               LV_MIN_LPS= 68 
    

    Note that in Example 2 the COPIES value has been changed to 1, and that the PP value is set equal to the LPs value. Make these changes to each of the lv_data stanzas in the image.data file. Once you make the changes, save the file and exit.

  7. Run another mksysb from the command line that will utilize your edited image.data file.
  8.  
               mksysb  /dev/rmtX   (where X is the number of your tape drive) 
    
    WARNING: Do not run the mksysb in smit because this will update the image.data file and overwrite any changes made.

    WARNING: Do not run the mksysb with the -i flag because this will update the image.data file as well.


Breaking Mirrors on an Existing mksysb

If another mksysb cannot be run, the following procedure can be used to restore a mksysb without mirroring.

NOTE: Access to another AIX system and an AIX formatted diskette is required to perform this procedure.

All references to the tape device in the next section are as rmt0.

  1. On another AIX system, place the mksysb tape in the tape drive. Change the block size of the tape drive to 512 by running:
  2.  
               chdev -l  rmt0 -a block_size=512 
    
  3. Create a temporary directory in /tmp called newdata.
  4.  
               mkdir /tmp/newdata 
    
  5. Change directory to /tmp/newdata.
  6.  
               cd  /tmp/newdata 
    
  7. Make sure that the tape is rewound.
  8.  
               tctl -f /dev/rmt0 rewind 
    
  9. Restore the image.data file from the second image of the mksysb tape.
  10.  
               restore -s2 -xqvf  /dev/rmt0.1  ./image.data 
    
  11. Edit the /tmp/newdata/image.data file, and make changes to each of the lv_data stanzas as indicated in the examples that follow. The lines that need changes are marked by --> and are boldfaced. In Example 4, the changes are made to those lines.
  12. To view and edit the file, execute:

     
               vi  image.data 
    
    Example 3
     
                       lv_data: 
                               VOLUME_GROUP= rootvg 
                               LV_SOURCE_DISK_LIST=  hdisk0 
                               LV_IDENTIFIER= 00000001113f3c62.5 
                               LOGICAL_VOLUME= hd4 
                               VG_STAT= active/complete 
                               TYPE= jfs 
                               MAX_LPS= 512 
                       -->     COPIES = 2   
                               LPs = 120   
                               STALE_PPs= 0 
                               INTER_POLICY= minimum 
                               INTRA_POLICY= center 
                               MOUNT_POINT= / 
                               MIRROR_WRITE_CONSISTENCY= on 
                               LV_SEPARATE_PV= yes 
                               PERMISSION= read/write 
                               LV_STATE= opened/syncd 
                               WRITE_VERIFY= off 
                               PP_SIZE= 4 
                               SCHED_POLICY= parallel 
                       -->     PP = 240   
                               BB_POLICY= relocatable 
                               RELOCATABLE= yes 
                               UPPER_BOUND= 32 
                               LABEL= / 
                               MAPFILE= 
                               LV_MIN_LPS= 68 
    

    Example 4

     
                       lv_data: 
                               VOLUME_GROUP= rootvg 
                               LV_SOURCE_DISK_LIST=  hdisk0 
                               LV_IDENTIFIER= 00000001113f3c62.5 
                               LOGICAL_VOLUME= hd4 
                               VG_STAT= active/complete 
                               TYPE= jfs 
                               MAX_LPS= 512 
                       -->     COPIES = 1   
                               LPs = 120   
                               STALE_PPs= 0 
                               INTER_POLICY= minimum 
                               INTRA_POLICY= center 
                               MOUNT_POINT= / 
                               MIRROR_WRITE_CONSISTENCY= on 
                               LV_SEPARATE_PV= yes 
                               PERMISSION= read/write 
                               LV_STATE= opened/syncd 
                               WRITE_VERIFY= off 
                               PP_SIZE= 4 
                               SCHED_POLICY= parallel 
                       -->     PP = 120   
                               BB_POLICY= relocatable 
                               RELOCATABLE= yes 
                               UPPER_BOUND= 32 
                               LABEL= / 
                               MAPFILE= 
                               LV_MIN_LPS= 120 
     
     
    

    Note that in Example 4 the COPIES value has been changed to 1, and that the PP value is set equal to the LPs value. Make these changes to each of the lv_data stanzas in the image.data file. Once you make the changes, save the file and exit.

  13. After making the changes to the image.data file, create a signature file. The signature file is required by the restore procedure.
  14.  
               echo data > signature 
    
  15. Format the diskette:
  16.  
               format /dev/rfd0 
    
  17. Back up the two files (image.data and signature) to the diskette drive:
  18.  
               find . -print |backup -iqvf /dev/rfd0 
    
  19. Verify that the two file were backed up, and that the diskette can be read:
  20.  
               restore -Tqvf /dev/rfd0 
    
  21. Reboot the target system off the mksysb tape with the diskette in the floppy drive, and follow the normal mksysb restore procedures. The edited version of the image.data file will be used to re-create the logical volumes without mirroring.

How to Restore a mksysb without Preserving Mirrors: restore.mksysb.nomirror.4x.bak ITEM: FAX
Dated: 98/09/15~00:00 Category: bak
This HTML file was generated 99/06/24~12:41:54
Comments or suggestions?
Contact us