IBM Support

Manual targeted cleanup scripts for WebSphere Application Server V5.0, 5.1, 6.0, 6.1, and 7.0 on AIX and IBM HTTP Server V1.3, 2.0, 6.0, 6.1, and 7.0 on AIX

Troubleshooting


Problem

Under some circumstances, the information associated with WebSphere® Application Server product installation stored in the AIX® ODM VPD can become corrupt or partially deleted. This will prevent the WebSphere Application Server product installer from working properly. This script cleans select WebSphere Application Server entries out of AIX ODM VPD to resolve issues installing new instances of the product.

Cause

The AIX Object Data Manager Vital Product Data tables (AIX ODM VPD) are used to track data associated with WebSphere Application Server V5.0, V5.1, V6.0, V6.1, and V7.0 and IBM® HTTP Server V1.3, V2.0, V6.0, V6.1, V7.0 product installations. For various reasons, these tables need to be cleaned to repair failed installations or uninstalls of WebSphere Application Server or IBM HTTP Server products. For more information concerning the use of the ODM VPD by WebSphere Application Server and descriptions of common problem scenarios, refer to the Explanation of AIX ODM VPD and its relationship with WebSphere Application Server products.

This article provides information about a specific method of cleaning the AIX ODM VPD using a "targeted manual cleanup script". This script was designed for use with WebSphere Application Server V5.x and IBM HTTP Server V1.3, V2.0, and is compatible with WebSphere Application Server V6.0, V6.1, V7.0 and IBM HTTP Server V6.0, V6.1, V7.0. It attempts to identify the entries associated with a single installation instance of a supported product in the AIX ODM VPD, and produces a customized cleanup script. The customized cleanup script will remove entries from the ODM, thereby allowing a new product installation instance to be placed into the same location.

This cleanup process has no effect on WebSphere Application Server V8.0 products. V8.0 products use IBM Installation Manager to manage the product installation process, and that installation process does not write WebSphere-specific entries to the ODM.

"Targeted cleanup" versus the "complete cleanup" procedure
Refer to technote 1231062 for a complete explanation of the cleanup process and a description of common symptoms which lead to this issue. Under most circumstances, it is actually recommended to use the "complete cleanup" procedure instead of this "targeted cleanup" procedure described here.

In general, this "targeted cleanup" script is advised for use on systems where one of the existing installation instances of a WebSphere Application Server (or IBM HTTP Server) product will be extended by a separate product (such as Lotus® Portal Server, WebSphere Commerce Suite, DB2® Content Manager). Separate products look for WebSphere-related entries in the ODM to determine whether or not a WebSphere product is present.

WebSphere Application Server V5 Embedded Messaging is not affected
These scripts do not affect entries related to Embedded Messaging or WebSphere MQ. The mqm and wemps entries associated with Embedded Messaging and WebSphere MQ remain intact in case an independent installation of WebSphere MQ is present, or another installation of an application server is utilizing Embedded Messaging on the system. It is safe to use these wipe scripts even when Embedded Messaging or WebSphere MQ is present on the system.

If it is necessary to clean up entries related to Embedded Messaging, then refer to the Information Center for your release for more details. Search for the article named "Manually uninstalling on AIX platforms" applicable to the appropriate version edition of WebSphere Application Server which needs to be wiped from the system.

Resolving The Problem


Effects of cleanup
It is very important to emphasize that the runtime of a WebSphere product will continue to function normally even if the installation data in the ODM is corrupt or deleted. Cleaning up the corruption will affect product upgrade functionality for the existing WebSphere product installations. The existing installations will experience only the following two peripheral effects:

  • The update installer wizard will not automatically detect the WebSphere products installed. Instead of selecting the product to update from an automatically generated list, you must manually input the directory of the WebSphere product installation. This is a nuisance but not a serious problem. (This does not affect the silent update installer utility, since the installation directory must be manually specified for that anyway.)

  • The WebSphere product cannot be extended by WebSphere Business Integration Server Foundation V5.1 or WebSphere Application Server Enterprise Edition V5.0. Those products will fail to install "on top of" a WebSphere installation which is missing its ODM data.

Again, the WebSphere product runtime will continue to function normally despite these issues.

Stage one: Generate the cleanup script
  1. Log in as the root user.

  2. Back up the existing ODM files. In order to do so, create backup copies of these files, all of which reside in the directory /usr/lib/objrepos:
    • inventory*
    • lpp*
    • product*
    • history*
    • vendor*
    • vpd.properties

      (The files marked with "*" represent two files. For example, inventory* is equivalent to inventory and inventory.vc)

      These backup files can be restored to their original location in case complications arise from the cleanup process.

      Note: AIX support does not condone manipulation of the ODM database files themselves. These ODM files should only be restored from backup if absolutely necessary. If they are restored, make sure to restore them from a very recent backup, and restore only the files listed above, and no others. (Do not backup or restore the other ODM files, as they are unaffected by this product and should not be manipulated.)

  3. Create a new temporary directory in which the root user has write access. This will be referenced as the "working directory". Make sure the file system has several (at least 2) megabytes free.

  4. Transfer the attached ODMclean.tar file to the working directory and extract it. The typical tar extraction command will work, as shown here:


    tar xvf ODMclean.tar

  5. Run the following script from within the working directory:


    ./generateODMclean.sh

  6. The script will display messages similar to the messages documented in this technote, and then it will prompt for input. When prompted, input the full path of the "old" previous WebSphere installation. The full path must be specified - do not use wildcards or relative directory addressing with "..". The cleanup script queries the ODM and not the file system, so the script will work even if the directory does not exist on the file system anymore. For example, a typical directory to specify would be one of the following:


    /usr/WebSphere/AppServer

    OR

    /usr/WebSphere/DeploymentManager

  7. Allow the script to process. It will take several minutes to process. Note that this is simply running queries and it is not actually altering your system.

  8. The script will produce several temporary files and a new script file named manualODMclean.sh. Collect all the files generated in the temporary directory, including manualODMclean.sh and preserve those files in a safe location.

    Note: In case a more thorough investigation is needed later, these logs will help IBM service determine what occurred during the cleanup process. If the cleanup process was successful, the files will no longer be needed, so they can be deleted after a reasonable period of time.

  9. Stage one is now complete. The manualODMclean.sh script is ready for review and then can be executed to clean the targeted product.

    Note: The manualODMclean.sh script is generated based off the current state of the ODM. Once the script is generated, any other alterations to the ODM (such as the installation of another product or a separate cleaning procedure) will deprecate the information recorded into the current manualODMclean.sh script. Once manualODMclean.sh is generated, it should be evaluated and used as quickly as possible. It can only be used on the system on which it was generated.



Stage two: Review and run manual cleanup script
Once the script is generated as per the instructions in stage one, follow these steps:
  1. To ensure that the script is restricted to cleaning only the appropriate entries, it is prudent to review it. As long as the script generator was provided with the correct input, then the manualODMclean.sh should identify and clean the necessary entries, without removing any other data.

    Review the manualODMclean.sh script as per the guidelines in technote 1237362. If the script appears to be good according to those guidelines, then proceed to step 2. If the script appears to be problematic, verify that it was provided with the correct product installation directory in Stage one. If this was the case, then consider using the complete cleanup script referenced earlier in the technote as an alternative solution.

  2. If the script looks like it is reasonably healthy, then it can be executed. It might be necessary to assign the script "execute" permissions. The script requires no parameters and no input. Run the script as follows:


    chmod +x manualODMclean.sh
    ./manualODMclean.sh

  3. Once the script has completed, rename it to a different name which implies that it has been used. For example, rename it to manualODMclean.finished.txt.

    This has a dual purpose: It ensures that no one is led to believe that this is a shell script which should be used again, and it also marks the file as having been used. The manualODMclean.sh script is a one-time use script which should not be used again on the same or any other system.

  4. Although the script is complete, the cleanup process is not yet complete. Please proceed to Stage three.


Stage three: Clean the vpd.properties file
The final stage of the cleanup process involves cleanup of the vpd.properties text file. Follow these steps to accomplish this:
  1. Log in as root user.

  2. Navigate to the /usr/lib/objrepos directory, and move the current vpd.properties file into a backup file. Execute the following commands:


    cd /usr/lib/objrepos
    mv vpd.properties vpd.properties.old

  3. Filter that text file and remove references to the installation path of the cleaned product. To accomplish this, run the following command. Substitute the path to the cleaned product in place of PRODUCT_DIR in this command. The path should be enclosed in quotes, as shown below. (This would be the same path which was provided as input to generateODMclean.sh in Stage one.)


    cat vpd.properties.old | grep -v "PRODUCT_DIR" >vpd.properties

  4. Bundle the vpd.properties.old file with the files which were preserved from Stage one and Stage two.

  5. The ODM VPD cleanup process is now complete. For clients using WebSphere Application Server V6.1, please proceed to the section below.


Additional cleanup step for V6.1 and V7.0 products
It is necessary to clean up the CIE registry (also called the "nifregistry"), which is separate from the ODM VPD. If the CIE Registry is not cleaned, then the installer might still claim that a copy of WebSphere Application Server V6.1 or V7.0 (or another related product) is present in the specified directory, even when the ODM VPD is clean.

Locate a copy of the installRegistryUtils tool, which is provided on the product installation image. (For example, it is located within the WAS/installRegistryUtils subdirectory of the WebSphere Application Server V6.1 product installation image.) The installRegistryUtils tool is also installed with the application server itself, with a script file in the product's bin directory.

Follow these steps to clean the CIE Registry:
  1. Using the root user (or sudo root) is recommended. If it is not possible to gain root access, then make sure to log in as the same user which was responsible for originally installing the version 6.1 product.

  2. After locating the installRegistryUtils tool, run the following command:


    ./installRegistryUtils.sh -listProducts

  3. Take note of the Offering ID and Install Location of the product installed in the location which is targeted for cleaning. If no products are listed in the targeted location, then stop now. No further action needs to be taken because the CIE Registry is clean.

  4. Clean the CIE Registry by issuing a command following this template:


    ./installRegistryUtils.sh -cleanProduct -offering OfferingID -installLocation InstallLocation


    Replace OfferingID and InstallLocation with the appropriate information noted in steps 2 and 3.

  5. Repeat step 2 to verify that the product has been cleaned from the CIE Registry. If the product is no longer listed, then the process is complete.



Download the targeted cleanup script here:

ODMclean.tar




DISCLAIMER
All source code and/or binaries attached to this document are referred to here as "the Program". IBM is not providing program services of any kind for the Program. IBM is providing the Program on an "AS IS" basis without warranty of any kind. IBM WILL NOT BE LIABLE FOR ANY ACTUAL, DIRECT, SPECIAL, INCIDENTAL, OR INDIRECT DAMAGES OR FOR ANY ECONOMIC CONSEQUENTIAL DAMAGES (INCLUDING LOST PROFITS OR SAVINGS), EVEN IF IBM, OR ITS RESELLER, HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

[{"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Install","Platform":[{"code":"PF002","label":"AIX"}],"Version":"7.0;6.1;6.0;5.1","Edition":"Edition Independent","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSEQTJ","label":"IBM HTTP Server"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Install","Platform":[{"code":"PF002","label":"AIX"}],"Version":"7.0;6.1;6.0;2.0.47;1.3.28;1.3.26","Edition":"All Editions","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Java SDK","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
07 September 2022

UID

swg21191336