01/23/96, 4FAX# 2588 Tips on mksysb for AIX 3.2.4 and Beyond SPECIAL NOTICES Information in this document is correct to the best of our knowledge at the time of this writing. Please send feedback by fax to "AIXServ Information" at (512) 823-4009. Please use this information with care. IBM will not be responsible for damages of any kind resulting from its use. The use of this information is the sole responsibility of the customer and depends on the customer's ability to eval- uate and integrate this information into the customer's operational environment. +----------------------------------------------------------+ | | | NOTE: The information in this document is NOT appli- | | cable for AIX 4.1. | | | +----------------------------------------------------------+ ABOUT THIS DOCUMENT This document is a collection of tips on the use of mksysb in AIX 3.2. It is divided into the following sections: Considerations Before Backing Up With mksysb . . . . . 2 Backing Up the System Disk in AIX 3.2 . . . . . . . . . 2 Verifying the mksysb Backup . . . . . . . . . . . . . 3 Troubleshooting Tips . . . . . . . . . . . . . . . . . 3 Doing a mksysb to a Networked File System . . . . . . . 4 Known Software Defects With mksysb After AIX 3.2.4 . . 4 Common Configuration and Setup Errors . . . . . . . . . 5 About Blocksize . . . . . . . . . . . . . . . . . . . . 6 About Density and rmtX.Y . . . . . . . . . . . . . . . 6 Reading/Restoring a File from a mksysb Tape . . . . . . 7 Installing a System from a mksysb Tape . . . . . . . . 8 Related Information . . . . . . . . . . . . . . . . . . 8 Faxing a Problem Report and Ordering a Fix Tape . . . . 8 Reader's Comments . . . . . . . . . . . . . . . . . . . 10 For information on the limitations of mksysb restoration, order fax number 2769 ("Limitations of mksysb Restoration") from 1-800-IBM-4FAX. For information on saving and restoring acl and tcb attri- butes, order fax number 2685 (Backup and Restore Access Control Lists During mksysb) from 1-800-IBM-4FAX. ATTENTION READERS OUTSIDE THE U.S.: You can order the above faxes and others mentioned later in this document by calling 415-855-4FAX from a fax machine phone. Tips on mksysb for AIX 3.2.4 and Beyond 1 01/23/96, 4FAX# 2588 CONSIDERATIONS BEFORE BACKING UP WITH MKSYSB o Please note that if you have InfoExplorer accessed via NFS or on a CD-ROM, the files under the mount point will not be backed up unless the file system containing InfoExplorer is unmounted. o If the ksh option "noclobber" is set, mksysb will fail in the BOSboot section. BACKING UP THE SYSTEM DISK IN AIX 3.2 The following are three different ways of calling the mksysb program to do a complete backup of all the JFS mounted file systems in the ROOTVG volume group. Three ways to back up rootvg volume group. smit startup smit mksysb mkszfile && mksysb /dev/rmtX.Y 2>&1 | tee /tmp/mksysb.out If you have more than one volume group (use "lsvg" to check), you must use one of the backup commands (backup, tar, pax or cpio) to back up the other volume groups, since mksysb only backs up the ROOTVG volume group. The mksysb backup makes a bootable tape that can be used to completely rebuild your system or to recover one or more files. It backs up everything in the ROOTVG volume group, including the ODM (Object Data Manager) data base. The ODM contains device configuration data. To make a mksysb bootable backup, 1. Log in as the "root" user 2. Type: "smit startup" 3. Select: "Backup the System" You will be asked to fill in the following screen: FORCE increase of work space if needed no * Backup DEVICE or FILE {} (example: /dev/rfd0) Fill in the correct device name to be used for the backup. Press the Enter key to start the backup. If the backup takes more than one tape, smit will prompt you to change the tape and press Enter. When the backup is fin- ished, make sure it completed successfully; errors can be seen in the smit.log file in the directory where the mksysb was executed. Tips on mksysb for AIX 3.2.4 and Beyond 2 01/23/96, 4FAX# 2588 Verifying the mksysb Backup After the backup is complete, it is a good idea to verify the tape. Verification can be done by checking the tar image and bootable portion as follows: To check the tar image of the data on the tape, use the fol- lowing commands: tctl -f /dev/rmtX rewind tctl -f /dev/rmtX.Y fsf 3 pax -vf /dev/rmtX Check the output for any error messages. To check the bootable portion, you will have to put the key in the service position and reboot the system with the tape in the drive. Once the menu appears, switch the key back to the Normal position and reboot the system. Always check to see that you have at least one good bootable tape. If for some reason your mksysb tape is not bootable, you can reinstall a mksysb tape using a set of bosboot diskettes. Since the mksysb tape can be used to completely rebuild your system, it is important that several backup tapes be main- tained and that these backups are done frequently. If you have questions about a backup schedule that is appropriate for your business, contact one of the following: o local branch office o your point of sale o 1-800-CALL-AIX (to register for fee-based services) All of the above avenues for assistance may be billable. TROUBLESHOOTING TIPS 1. If you get errors from mksysb, check the FIRST error message given. This is the one that indicates the direct cause of the problem. 2. Make sure you have enough free blocks in the file systems to write temporary files. See "Common Confuration and Setup Errors", error code 0512-016. 3. Make sure you are using the correct tape type for the density setting selected. See "About Density and rmtX.Y". 4. Check that the block size is properly set. See "About Blocksize". 5. Make sure the tape IS NOT write protected. See "common Configuration and Setup Errors", error code 0512-016, return code 2. 6. Clean the tape drive at the recommended intervals and only use approved data grade tapes (not video tapes for 8mm). Tips on mksysb for AIX 3.2.4 and Beyond 3 01/23/96, 4FAX# 2588 7. Check the file smit.log (located in the directory where the mksysb was executed) for any errors from smit. 8. 7206 4mm DAT tape drives can only use DAT tapes marked with the "DDS ||||" symbol. Any other DAT tapes (i.e., voice grade) will not work. 9. Each of the file systems must have at least 500 blocks free when the mksysb backup is made. The system will need some work space in each file system when it is installing from a mksysb backup. Refer to "common Con- figuration and Setup Errors". 10. Be sure your mksysb backup is made with a current ".fs.size" file. If you create your mksysb backup through smit, it will do this automatically. If you run mksysb from the command line, you need to run "mkszfile" first: mkszfile && mksysb /dev/rmtX.Y 2>&1 | tee /tmp/mksysb.out DOING A MKSYSB TO A NETWORKED FILE SYSTEM The procedure for doing a mksysb to a networked file system is documented in the installation guide in the chapter "Cre- ating an Installation Server." KNOWN SOFTWARE DEFECTS WITH MKSYSB AFTER AIX 3.2.4 o 7318 attached tty configurations are not backed up by mksysb. Fix: IX48513 o "0512-005 mksysb failed" If this is the FIRST error message in the output and the system level is 3.2.5, check the output for files that were not backed up. This error message occurs because tar has been changed to return an error code if it cannot find one or more of the files from the list that the find command builds. The user needs to determine if it is acceptable that the particular files are missing. Fix: IX41023 and IX40808 o A mksysb from ASCII SMIT runs longer than it did in the previous release by a factor of three or more. Workaround: Instead of using SMIT, run "mkszfile && mksysb" from the command line: mkszfile && mksysb /dev/rmtX.Y 2>&1 | tee /tmp/mksysb.out Fix: IX40960 o "Catastrophe in realloc, invalid storage ptr" during a mksysb from MOTIF SMIT with X11r5. Fix: IX39680 Tips on mksysb for AIX 3.2.4 and Beyond 4 01/23/96, 4FAX# 2588 o Non-JFS mount points are not backed up by mksysb. Fix: IX41017 o Mksysb does not backup the ACL list or TCB attributes. Fix: IX41592 o 0512-010 -- Mksysb fails to create backup list. Fix: IX44315 o Tar does not return consistent return codes. Fix: IX43796 COMMON CONFIGURATION AND SETUP ERRORS o "A system call received an invalid argument." If you are using a 1/4" tape drive, this unnumbered message indicates that the tape cartridge cannot be used to write at the density specified. For more information on tape drive densities, order fax number 1896 ("Tape Drive Densities and Special Files") from 1-800-IBM-4FAX. o "0512-004: The /.fs.size file does not exist. System backup canceled." Either the / or /tmp file system is not big enough, or mksysb was run outside of smit (from the command line or from a script) without the mkszfile command being run first. Use this syntax when running mksysb from the command line: mkszfile && mksysb /dev/rmtX.Y 2>&1 | tee /tmp/mksysb.out o "0512-016: Attempt to create a bootable tape failed:" "bosboot -d /dev/device -a failed with return code NUMBER" (OR) "mkinsttape /dev/device failed with return code NUMBER" where "NUMBER" is: 2 Media is write protected. 5 OR 1 Not enough space in the file systems. / must have at least 500 1K blocks /tmp must have at least 7400 1K blocks /usr must have at least 4000 1K blocks 11 Defective tape. Tips on mksysb for AIX 3.2.4 and Beyond 5 01/23/96, 4FAX# 2588 42 OR 45 /usr/lib/boot/unix is corrupted (maybe 0 length) or the link to /unix is missing. Restore from original tape or create the missing link. 48 Cannot write to the tape drive or cannot read /dev/blv. This is probably caused by an incorrect density setting for the tape-drive/tape- type/device-name combination. It could also be caused by a tape drive hardware problem or by dirty tape heads on the tape drive. If you are still experiencing configuration problems and need further assistance, contact one of the following: o local branch office o your point of sale o 1-800-CALL-AIX (to register for fee-based services) All of the above avenues for assistance may be billable. ABOUT BLOCKSIZE Tape Size Recommended Blocksize --------- --------------------- 8 mm 1024 1/4 " 512 For more detailed information regarding tape device drivers, order fax number 2208 ("Tape Device Drivers Notes for AIX 3.1 and 3.2") from 1-800-IBM-4FAX. ABOUT DENSITY AND RMTX.Y There are two density settings in AIX. You can see and change the density settings by typing "smit chgtpe". Here are some possible values for the density settings: Density Format Drive Type ------- ------ ---------- 17 QIC 525 7207 Model 011 16 QIC 150 7207 Model 011 15 QIC 120 7207 Model 011 NOTE: Density "00" is the factory power-on default or the last saved permanent MODE select density as set by the using system. The default is QIC 525 for 7207 Model 011. There are eight rmtX.Y drive specifications, where "X" is a number specifying the drive and "Y" is a number specifying the drive action. Tips on mksysb for AIX 3.2.4 and Beyond 6 01/23/96, 4FAX# 2588 Special File Retension Setting Rewind Setting Density Setting ------------ ----------------- -------------- --------------- rmtX no yes 1 rmtX.1 no no 1 rmtX.2 yes yes 1 rmtX.3 yes no 1 rmtX.4 no yes 2 rmtX.5 no no 2 rmtX.6 yes yes 2 rmtX.7 yes no 2 EXAMPLE: For a 7207-011 tape drive with settings DENSITY setting #1 {17} DENSITY setting #2 {16} you would use o a 6525 (QIC 525) tape for "rmtX", "rmtX.1", "rmtX.2" & "rmtX.3" o a 6250 (QIC 150) tape for "rmtX.4", "rmtX.5", "rmtX.6" & "rmtX.7" For further tape drive configuration information, order doc- ument 1896 ("Tape Drive Densities and Special Files") from the IBM Fax Information Service, 1-800-IBM-4FAX. READING/RESTORING A FILE FROM A MKSYSB TAPE The mksysb tape is written as four separate files of data. The first three files are the bootable portion and the fourth file contains the actual data. Here, we use the "tctl" command to skip past the boot partitions. In the following commands, "Y" must indicate a no-rewind device. To read the table of contents from the tape: tctl -f /dev/rmtX rewind tctl -f /dev/rmtX.Y fsf 3 tar -tvf /dev/rmtX To restore a file: cd / tctl -f /dev/rmtX rewind tctl -f /dev/rmtX.Y fsf 3 tar -xvf /dev/rmtX ./path_name/file_name NOTE: The path name must start with a '.' because a mksysb backup is a relative backup. Tips on mksysb for AIX 3.2.4 and Beyond 7 01/23/96, 4FAX# 2588 INSTALLING A SYSTEM FROM A MKSYSB TAPE You can install a system from a mksysb tape by following the steps listed in chapter 3 of the AIX Installation Guide. Please be aware of the following error conditions which could occur during an installation from a mksysb tape: o Resource allocation errors occur during the creation of logical volumes. When a system is installed from a mksysb tape, the paging space is recreated at twice the size of main memory at the time of the reinstallation (unless main memory is greater than 32 MB, in which case paging space is created at the size of main memory plus 16 MB). The paging space will be allocated across the physical disks that you are installing across but will not take up more than 20 percent of any one disk. If you have increased memory and if there is not enough free disk space to hold the corresponding increase in paging space, there will be problems with the creation of logical volumes during installation. If you encounter this error, you should leave the system as it is and contact your branch office to discuss the recovery options. o Tar fails with a return code 1 while it is restoring the files. This means that one of the file systems has run out of free space. If you encounter this error, you should leave the system as it is and contact your branch office to discuss the recovery options. There is more than one way to recover, and your branch office can help you determine the best method for your situation. RELATED INFORMATION See the AIX documentation for mkszfile, mksysb, tctl, tar, dd, and pax for additional information. FAXING A PROBLEM REPORT AND ORDERING A FIX TAPE If you have checked all of the above and need us to send a fix for a known problem, or if you are still having a problem that you believe is a software defect, fill in the following problem report form and fax it to 512-823-9468. Tips on mksysb for AIX 3.2.4 and Beyond 8 01/23/96, 4FAX# 2588 AIX RISC SYSTEM/6000 PROBLEM REPORT COMMANDS GROUP Fax to 512/823-9468 Customer Number _________________ Contact Name _____________________________ (Required Field) Problem # (if already open problem) ________________________________________ Company Name ____________________________________________________________ Address #1 ____________________________________________________________ Address #2 ____________________________________________________________ City, ST, Zip ____________________________________________________________ Voice Phone # _____-_____-______________ Fax Phone # _____-_____-______________ System Model # __________________________ AIX S/W level ___________________ (Use lslpp -h bos.obj to check) Failing Command __________________________ Exact error message ________________________________________________________ ________________________________________________________ Tape drive model number __________________ Tape type _______________________ (Use smit chgtpe to view the following:) (If available:) Density #1 setting __________ Density #2 setting ___________ Extended file marks ____ Data compression ____ Block size____ Problem description and how to recreate: ___________________________________ ____________________________________________________________________________ ____________________________________________________________________________ If your problem description matches one of the known software defects, check to see if the corresponding PTF is already installed on your system. Use lslpp -h U###### and if there is no output, you need to order that PTF. If there is an output when doing the lslpp -h command, please write the results on the line below: lslpp output:_______________________________________________________________ Preferred update media: 8mm _________ 1/4 inch ______________ *** Please fax the above form to (512) 823-9468 *** Tips on mksysb for AIX 3.2.4 and Beyond 9 01/23/96, 4FAX# 2588 READER'S COMMENTS Please fax this form to (512) 823-4009, attention "AIXServ Informa- tion". You may also e-mail comments to: elizabet@austin.ibm.com. These comments should include the same customer information requested below. Use this form to tell us what you think about this document. If you have found errors in it, or if you want to express your opinion about it (such as organization, subject matter, appearance) or make sug- gestions for improvement, this is the form to use. If you need technical assistance, contact your local branch office, point of sale, or 1-800-CALL-AIX (for information about support offer- ings). These services may be billable. Faxes on a variety of sub- jects may be ordered free of charge from 1-800-IBM-4FAX. Outside the U.S. call 415-855-4329 using a fax machine phone. When you send comments to IBM, you grant IBM a nonexclusive right to use or distribute your comments in any way it believes appropriate without incurring any obligation to you. NOTE: If you have a problem report or item number, supplying that number may help us determine why a procedure did or did not work in your specific situation. Problem Report or Item #: Branch Office or Customer #: Be sure to print your name and fax number below if you would like a reply: Name: Fax Number: ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ ______________________________________________________________________ END OF DOCUMENT (mksysb.324+.bak, 4FAX# 2588) Tips on mksysb for AIX 3.2.4 and Beyond 10