[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Commands Reference, Volume 4

nimadm Command

Purpose

Performs Alternate Disk Migration to a new version or release of AIX using NIM resources.

Syntax

Perform Alternate Disk Migration:

nimadm -l lpp_source -c NIMClient -s SPOT -d TargetDisks [ -a PreMigrationScript ] [ -b installp_bundle] [ -z PostMigrationScript] [ -e exclude_files] [ -i image_data ] [ -m NFSMountOptions ] [ -o bosinst_data] [-P Phases] [-Y ] [ -F ] [ -D ] [ -E ] [ -V ] [ { -B | -r } ]

Cleanup Alternate Disk Migration on client:

nimadm -C NIMClient -s SPOT [ -F ] [ -D ] [ -E ]

Wake-up Volume Group:

nimadm -W -c NIMClient -s SPOT -d TargetDisks [-m NFSMountOptions ] [-z PostMigrationScript ] [ -F ] [ -D ] [ -E ]

Put-to-sleep Volume Group:

nimadm -S -c NIMClient -s SPOT [ -F ] [ -D ] [ -E ]

Description

nimadm (Network Install Manager Alternate Disk Migration) is a utility that allows the system administrator to create a copy of rootvg to a free disk (or disks) and simultaneously migrate it to a new version or release level of AIX. nimadm uses NIM resources to perform this function.

There are several advantages to using nimadm over a conventional migration:

  1. Reduced downtime. The migration is performed while the system is up and functioning normally. There is no requirement to boot from install media, and the majority of processing occurs on the NIM master.
  2. nimadm facilitates quick recovery in the event of migration failure. Since nimadm uses alt_disk_install to create a copy of rootvg, all changes are performed to the copy (altinst_rootvg). In the even of serious migration installation failure, the failed migration is cleaned up and there is no need for the administrator to take further action. In the event of a problem with the new (migrated) level of AIX, the system can be quickly returned to the pre-migration operating system by booting from the original disk.
  3. nimadm allows a high degree of flexibility and customization in the migration process. This is done with the use of optional NIM customization resources: image_data, bosinst_data, exclude_files, pre-migration script, installp_bundle, and post-migration script.

Please note that this document will only address subjects pertaining to nimadm. For complete coverage of alt_disk_install, NIM, migration, and other related install issues please refer to the latest editions of the following publications:

nimadm Requirements

The nimadm requirements are:

  1. Configured NIM master running AIX 5.1 or higher with AIX recommended maintenance level 5100-03 or higher.
  2. The NIM master must have the same level of bos.alt_disk_install.rte installed in its rootvg and the SPOT which will be used to perform the migration. (Note: it is not necessary to install the alt_disk_install utilities on the client).
  3. The selected lpp_source NIM resource, and selected SPOT NIM resource must match the AIX level to which you are migrating.
  4. The NIM master should be at the same or higher AIX level then the level being migrated to.
  5. The client (the system to be migrated) must be at AIX 4.3.3.0 or higher.
  6. The client must have a disk (or disks) large enough to clone the rootvg and an additional 500 Megs (approximately) of free space for the migration. The total amount of required space will depend on original system configuration and nimadm customization.
  7. The target client must be a registered with the master as a standalone NIM client (see the niminit command for more information).The nim master must be able to execute remote commands on the client using the rshd protocol.
  8. The nim master must be able to execute remote commands on the client using the rshd protocol.
  9. The NIM master and client must both have a minimum of 128 megabytess of RAM.
  10. A reliable network, which can facilitate large amounts of NFS traffic, must exist between the NIM master and the client. The NIM master and client must be able to perform NFS mounts and read/write operations.
  11. The client's hardware and software should support the AIX level that is being migrated to and meet all other conventional migration requirements.
Note
If you cannot meet requirements 1-10, you will need to perform a conventional migration. If you cannot meet requirement 11, then migration is not possible.

Attention: before performing a nimadm migration you will be required to agree to all software license agreements for software to be installed. You can do this by specifying the "-Y" flag as an argument to the nimadm command or setting the ADM_ACCEPT_LICENSES environment variable to "yes".

nimadm Limitations

The following limitations apply to nimadm:

  1. If the client's rootvg has TCB turned on, you will need to either disable it (permanently) or perform a conventional migration. (This limitation exists because TCB needs to access file metadata which is not visible over NFS).
  2. All NIM resources used by nimadm must be local to the NIM master.
  3. Although there is almost no interference with the client's active rootvg during the migration, the client may experience minor performance decrease due to increased disk i/o, biod activity, and some CPU usage associated with alt_disk_install cloning.
  4. NFS tuning may be required to optimize nimadm performance.

NIM resources used by nimadm:

SPOT resource (-s flag)
The NIM spot resource is required for all nimadm operations (migration, cleanup, wake-up, sleep). All nimadm and alt_disk_install utilities that will be used by the client are installed in this resource. It is not necessary to install nimadm software on the client. The NIM "cust" operation should be used to install the following filesets into the spot:
lpp_source resource (-l flag)
This NIM resource is the source of install images that will be used to migrate the system. It is required for nimadm migration operations. The lpp_source must contain all system images for the level being migrated to (check the lpp_source simages attribute in lsnim -l lpp_source output). It should also contain any optional installp images that need to be migrated.
pre-migration
This script resource that is run on the NIM master, but in the environment of the client's alt_inst file system that is mounted on the master (this is done by using the chroot command). This script is run before the migration begins.
post-migration
This script resource is similar to the pre-migration script, but it is executed after the migration is complete.
image_data
Specifies an image_data resource that is passed to alt_disk_install (as arguments to the -i flag). NIM will allocate and mount this resource on the client before calling alt_disk_install.
exclude_files
Specifies an exclude_files resource that is passed to alt_disk_install (as an argument to the -e flag). NIM will allocate and mount this resource on the client before calling alt_disk_install.
installp_bundle
This NIM resource specifies any additional software that nimadm will install after completing the migration.
bosinst_data
This NIM resource specifies various install settings that may be used by nimadm.

The nimadm Migration Process

nimadm performs migration in 12 phases. Each phase can be executed individually using the -P flag. The user should have a good understanding of the nimadm process before performing a migration in phases. The nimadm phases are as follows:

  1. The master issues an The alt_disk_install command to the client which makes a copy of the rootvg to the target disks (coincidentally this is Phase 1 of the alt_disk_install process). In this phase altinst_rootvg (alternate rootvg) is created.
  2. The master runs remote client commands to export all of the /alt_inst file systems to the master. The file systems are exported as read/write with root access to the master.
  3. The master NFS mounts the file systems exported in Phase 2.
  4. If a pre-migration script resource has been specified, it is executed at this time.
  5. System configuration files are saved. Initial migration space is calculated and appropriate file system expansions are made. "bos" is restored and the device database is merged (similar to a conventional migration). All of the migration merge methods are executed and some miscellaneous processing takes place.
  6. All system filesets are migrated using installp. Any required RPM images are also installed during this phase.
  7. If a post-migration script resource has been specified, it is executed at this time.
  8. bosboot is executed to create a client boot image, which is written out to the client's boot logical volume (hd5).
  9. All mounts made on the master in phase 3 are removed.
  10. All client exports created in phase 2 are removed.
  11. alt_disk_install is called again (phase 3 of alt_disk_install) to make final adjustments and put altinst_rootvg to sleep. The bootlist is set to the target disk (unless the -B flag is used).
  12. Cleanup is executed to end the migration. The client is rebooted, if the "-r" flag is specified.
Note
nimadm supports migrating several clients simultaneous.

nimadm Cleanup Operation

This operation, indicated with the "-C" flag, is designed to clean up after a failed migration that for some reason did not perform a cleanup it self. It can also be used to clear a previous migration in order to perform a new migration.

nimadm Wake-up and Sleep

After a migration completes, nimadm can be used to "wake-up" the migrated altinst_rootvg or the original rootvg (if booted from the migrated disk). The nimadm wake-up (-W flag) performs an alt_disk_install wakeup, NFS exports the /alt_inst file systems, and mounts them on the NIM master. The nimadm sleep function (-S flag) reverses the wake-up by unmounting the NIM master mounts, unexporting the /alt_inst file systems, and executing the alt_disk_install "sleep" function on the client.

Flags

-a PreMigrationScript Specifies the pre-migration NIM script resource.
-b installp_bundle Specifies the installp_bundle NIM resource.
-B Specifies not running bootlist after nimadm migration. If set, then -r flag cannot be used.
-c TargetDisks Specifies the NIM defined client which will be the target of this nimadm operation. This flag is required for all nimadm operations.
-C Performs nimadm cleanup.
-d TargetDisks Specifies the client target disk which will be used to create altinst_rootvg (the volume group that will be migrated).
-D Sets nimadm into debug mode. This function should only be used to debug nimadm related problems and is not set by default.
-e exclude_files Specifies the exclude_files NIM resource. This resource is used by the alt_disk_install command during Phase 1.
-E Enters the nimadm debugger if a serious migration error occurs.
-F Forces a client to unlock. Normally, nimadm locks a client to perform various operations. While the client is locked, other nimadm or NIM operations cannot be performed. This flag should ONLY be used in the unusual condition that a client is incorrectly locked (this can happen if for some reason nimadm could not call cleanup after a failure).
-i image_data Specifies the image_data NIM resource. This resource is used by the alt_disk_install command during Phase 1 and 11.
-l lpp_source Specifies the lpp_source NIM resource to be used for this nimadm operation. This flag is required for migration operations.
-m NFSMountOptions Specifies arguments which will be passed to the mount command that mounts client resources on the master. This flag can be used to tune nimadm related NFS performance.
-o bosinst_data Specifies bosinst_data NIM resource.
-P Phase The phase to execute during this invocation of nimadm. If there is more then one phase, the phases should be separated by spaces or commas. Valid phases are 1 through 12.
-r Specifies that the client should reboot after nimadm migration is complete.
-s SPOT Specifies the SPOT NIM resource to be used for this nimadm operation. This flag is required for all nimadm operations.
-S Performs the nimadm "sleep" function. This function should be executed to end a nimadm "wake-up".
-V Turns on verbose output.
-W Performs the nimadm "wake-up" function.
-Y Agrees to required software license agreements for software to be installed.
-z PostMigrationScript Specifies the post-migration NIM script resource.

Exit Status

0
All nimadm related operations completed successfully.
>0
An error occurred.

Security

Only the root user can execute nimadm.

Examples

  1. To execute nimadm migration to target NIM client aix1, using NIM SPOT resource spot1, NIM lpp_source resource lpp1, and target disks hdisk1 & hdisk2. Note, the "-Y" flag agrees to all required software license agreements for software to be installed, enter the following:
    nimadm -c aix1 -s spot1 -l lpp1 -d "hdisk1 hdisk2" -Y
  2. To execute the same operation as in the example above to hdisk2, and also run pre-migration script nimscript1 and post-migration script nimscript2, enter the following:
    nimadm -c aix1 -s spot1 -a nimscrip1 -z nimscript2 -l lpp1 -d hdisk1 -Y
  3. To execute nimadm cleanup on client aix1, using NIM SPOT resource spot1, enter the following:
    nimadm -C -c aix1 -s spot1

Files

/usr/sbin/nimadm Contains the nimadm command.

Related Information

The lslpp command, the nim command, the lsnim command, the alt_disk_install command, the installp command, the chroot command.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]