mkszfile Command

Purpose

Saves the system state for reinstallation on the current system or another system.

Syntax

mkszfile [ -X] [ -d directory ] [ -m] [ -G ] [ -N ] [-x file ]

Description

Attention: The mkszfile command overwrites an existing /image.data file with new information.

The mkszfile command saves the system state for reinstallation on the current system or on another system. The information saved includes the following:

  • System installation information
  • Logical volume information for the root volume group
  • File system information.

The saved information allows the bosinstall routine to recreate the logical volume information as it existed before the backup.

The mkszfile command creates the /image.data file. The contents of this file are defined by the system in which the image was created. The user can edit the /image.data file before calling the mksysb command. The mksysb command, in turn, only backs up the file systems specified in the /image.data file, which reflects the requirements of the rootvg file system.

All the saved information is obtained using list commands. The commands are listed in the /image.data file as comments for the user's reference when editing this file.

Files on tape cannot be changed. However, in order to override the data files on the tape, the user can create a diskette with the desired files.

The mkszfile command checks to be sure there is at least 8MB of free space available in the /tmp file system for the boot image.

Note:
  1. Before running the mkszfile command, ensure that enough space is available in the /tmp file to store a boot image. This space is needed during both backup and installation. To determine the amount of space needed in the /tmp file, issue one of the following commands: bosboot -qad rmt or bosboot -qad ipldevice.
  2. If you remove the /dev/ipldevice prior to executing the mkszfile command, the 0301-150 bosboot error occurs. This message, in most cases, can be ignored. Confirm the success of the mkszfile command by the return code.

Flags

Item Description
-m Creates map files that specify the mapping of the logical-to-physical partitions for each logical volume in the volume group. This mapping can be used to allocate the same logical-to-physical mapping when the image is restored. The map file locations are stored in the MAPFILE field in the /image.data file for each logical volume. Sufficient space would exist in the /tmp file system for map creation because the installation routines place the maps in the /tmp file system before issuing the mklv command.

For example, for the hd7 logical volume, the location of the map file is /tmp/vgdata/rootvg/hd7.map. The MAPFILE field in the /image.data file for the hd7 logical volume is under the entry MAPFILE=/tmp/vgdata/rootvg/hd7.map.

The map files in the backup image are copied after the /bosinst.data and /image.data files.

-N Includes file systems that belong to a workload partition (WPAR) in the defined state in the /image.data file.
Note: To be included in the /image.data file, all file systems that belong to a WPAR in the defined state need to be in the rootvg volume group.
-X Expands /tmp if needed.
-d Write the image.data file to the specified directory instead of /.
-G Excludes the WPAR file systems from the /image.data file. This flag is not valid with -N flag.
-x file Excludes the file systems that are listed in the file from the image.data file. File system mount points must be listed one per line.
Note: Use care when excluding file systems as a resulting backup can be unusable for system restoration.

Files

Item Description
/usr/bin/mkszfile Contains the mkszfile command.