Install Liberty on IBM i operating systems using response files

We can install all WebSphere Application Server Liberty offerings on IBM i operating systems using Installation Manager response files.

Prepare for the installation before using this procedure.

See Prepare the operating system for installation on IBM i for more information.

To install Liberty assets from local directory-based repositories or an instance of the Liberty Asset Repository Service, configure the repositories. For more information about the Liberty asset repositories, see Install assets using Installation Manager.

Important:

  • Before installing Liberty, we must read the license agreement we can find with the product files. Signify your acceptance of the license agreement by specifying -acceptLicense in the command as described in this topic.

  • The minimum acceptable version of IBM Installation Manager for installing Liberty is 1.9.0 or later. Do not use IBM Installation Manager 1.10.x on the IBM i platform.

    See the IBM Support page.

  1. Download IBM Installation Manager.There are three basic options for accessing Installation Manager installation files.

    • Download the most current version of Installation Manager version 1.9.x from the IBM Installation Manager download website. Do not use Installation Manager 1.10 on the IBM i platform. For more information, see the IBM Support page.
    • Install Installation Manager from product repositories on the media.
    • Download the files from the Passport Advantage site, and use local installation

      Licensed customers with a Passport Advantage ID and password can download the necessary product repositories from the Passport Advantage site.

  2. Choose three separate locations for Installation Manager's binaries, runtime data (agent data), and shared data locations.

  3. Install Installation Manager using the Installation Manager command line.

    1. Sign on to the IBM i system with a user profile that has *ALLOBJ and *SECADM special authorities.

    2. On a CL command line, run the STRQSH command to start the Qshell command shell.

    3. Make sure that the umask is set to 022.To verify the umask setting, issue the following command:

        umask

      To set the umask setting to 022, issue the following command:

        umask 022

    4. Make sure that the PATH environment variable is set to the system default value of /usr/bin:.:/QOpenSys/usr/bin.

        export PATH=/usr/bin:.:/QOpenSys/usr/bin

    5. Change to the location containing the Installation Manager installation files, and run the following command:

        installc -acceptLicense -log log_file_path_and_name

      Notes:

  1. Optional: If the repository requires a user name and password, create credential-storage and master-password files to access this repository.

    1. Optional: Create the main password file.

      The main password file is a text file containing a passphrase such as This text is the main password. This file is used to secure your authentication credentials.

      If we create a main password file and use it when we create credentials, we must always specify the main password file. Tip: To secure this file, set permissions to restrict access to this file as appropriate for the operating system.

    2. Create a credential storage file using the imutilsc saveCredential command.

        ./imutilsc saveCredential 
          -secureStorageFile storage_file
          -userName user_ID -userPassword user_password
          -url repository_URL_or_path 

      Tip: If the imutilsc command is unable to find the URL specified when we create the credential storage file, append /repository.config at the end of the repository URL location.

  2. Sign on to the IBM i system with a user profile that has *ALLOBJ and *SECADM special authorities.

  3. When installing WebSphere Liberty on an IBM i system with multiple languages installed, be aware of these NLS considerations before beginning your install. Make sure your LANGID, CNTRYID and CCSID job attributes all match the same row in this NLS table that correspond with your LANG environment variable value.

  4. On a CL command line, run the STRQSH command to start the Qshell command shell.

  5. Make sure that the umask is set to 022. To verify the umask setting, issue the following command:

      umask

    To set the umask setting to 022, issue the following command:

      umask 022

  6. Make sure that the PATH environment variable is set to the system default value of /usr/bin:.:/QOpenSys/usr/bin.

      export PATH=/usr/bin:.:/QOpenSys/usr/bin

  7. Use a response file to install the product. Change to the eclipse/tools subdirectory in the directory where we installed Installation Manager, and install the product. For example:

      ./imcl -acceptLicense 
        input $HOME/WASFiles/temp/install_response_file.xml 
        -log $HOME/WASFiles/temp/install_log.xml 
        -secureStorageFile $HOME/WASFiles/temp/credential.store -masterPasswordFile $HOME/WASFiles/password_file.txt

    Notes:

    • The relevant terms and conditions, notices, and other information are provided in the license-agreement files in the lafiles or product_name/lafiles subdirectory of the installation image or repository for this offering.
    • /QIBM/ProdData/InstallationManager is the default installation location for Installation Manager files on IBM i systems.

    • The program might write important post-installation instructions to standard output.

    Read the IBM Installation Manager product documentation for more information.


Example

The following is an example of a response file for installing the product with no optional features into the /QIBM/ProdData/WebSphere/Liberty/ND directory using a web-based repository located at http://www.ibm.com/software/repositorymanager/com.ibm.websphere.liberty.ND.

    <?xml version="1.0" encoding="UTF-8"?>
    <agent-input>
    <server>
      <repository location='http://www.ibm.com/software/repositorymanager/com.ibm.websphere.liberty.ND'/>
    </server>
    <profile id='WebSphere Liberty' installLocation='/QIBM/ProdData/WebSphere/Liberty/ND'>
      <data key='was.install.os400.profile.location' value='/QIBM/UserData/WebSphere/Liberty/ND'/>
      <data key='user.import.profile' value='false'/>
    </profile>
    <install modify='false'>
      <offering profile='WebSphere Liberty' 
        features='' id='com.ibm.websphere.liberty.ND'/>
    </install>
    <preference name='com.ibm.cic.common.core.preferences.eclipseCache' 
      value='/QIBM/UserData/InstallationManager/IMShared'/>
    <preference name='com.ibm.cic.common.core.preferences.connectTimeout' value='30'/>
    <preference name='com.ibm.cic.common.core.preferences.readTimeout' value='30'/>
    <preference name='com.ibm.cic.common.core.preferences.downloadAutoRetryCount' value='0'/>
    <preference name='offering.service.repositories.areUsed' value='true'/>
    <preference name='com.ibm.cic.common.core.preferences.ssl.nonsecureMode' value='false'/>
    <preference name='com.ibm.cic.common.core.preferences.http.disablePreemptiveAuthentication' value='false'/>
    <preference name='http.ntlm.auth.kind' value='NTLM'/>
    <preference name='http.ntlm.auth.enableIntegrated.win32' value='true'/>
    <preference name='com.ibm.cic.common.core.preferences.preserveDownloadedArtifacts' value='true'/>
    <preference name='com.ibm.cic.common.core.preferences.keepFetchedFiles' value='false'/>
    <preference name='PassportAdvantageIsEnabled' value='false'/>
    <preference name='com.ibm.cic.common.core.preferences.searchForUpdates' value='false'/>
    </agent-input>
    

Tips:

  • New: By default, all Liberty features that apply to your product edition are installed when we install Liberty. Rather than installing all features, we can install a custom set of Liberty addons and features by specifying them on the user.addon and user.feature properties, as shown in the following example. Note the feature short names or symbolic names must be separated by double commas.The following example installs the MicroProfile Health 4.0 (mphealth-4.0) and the MicroProfile Metrics 4.0 (mpMetrics-4.0) features using the short name, and the Extended Program Models addon.

      <data key='user.feature' value='com.ibm.websphere.appserver.mphealth-4.0,,mpMetrics-4.0'/>
      <data key='user.addon' value='extendedPackage-1.0'/>
      <data key='user.accept.license' value='true'/>
      

    We can install assets from instances of the Liberty Asset Repository Service or local directory-based repositories with or without internet access.

    See Install assets using Installation Manager. Add the repository URL, directory, or archive path on repository elements. If Installation Manager does not recognize the repository, point directly to the repository.config file. When installing assets, the repositories are accessed in the order specified them.

      <server>
      <repository location="http://www.ibm.com/software/repositorymanager/com.ibm.websphere.liberty.ND" />
      <repository location="https://your_onprem_asset_repo_url" />
      <repository location="/QIBM/LocalAssetRepo" />
      <repository location="/QIBM/LocalAssetRepo2.zip" />
      </server>

    To enable access to the Liberty Repository, on a data element, set the user.useLibertyRepository parameter to true. The Liberty Repository is the last of the repositories that are accessed during installation.

      <data key='user.useLibertyRepository' value='true'/>

    Important: If we do not want to install Liberty addons or features, specify empty values for the user.addonuser.feature properties:

      <data key='user.feature' value=''/>
      <data key='user.addon' value=''/>

    See the following topics:

  • Make sure that the repository location points to the web-based or local product repository. For example:

      <repository location='https://downloads.mycorp.com:8080/WAS_Liberty_repository'/>

  • The following line from the example specifies the default value of the profile location for IBM i:

      <data key='was.install.os400.profile.location' value='/QIBM/UserData/WebSphere/Liberty/ND'/>

    To override this default location, specify a different location

  • The following line from the example specifies the default value of the shared resources directory for IBM i:

      <preference name='com.ibm.cic.common.core.preferences.eclipseCache' value='/QIBM/UserData/InstallationManager/IMShared'/>

    To override this default location, specify a different location

    Note that there is only one shared resources directory for Installation Manager. If there has been an installation on the system in the past, it will use that shared resources directory and not the one specified in the response file.

  • To disable remote searches for updates in the response file, set the following preferences to false:

    • offering.service.repositories.areUsed

      Used for searching remote repositories for updates to installed offerings

    • com.ibm.cic.common.core.preferences.searchForUpdates

      Used for searching for updates to Installation Manager

    For example:

      <preference value='false' name='offering.service.repositories.areUsed'/>
      <preference value='false' name='com.ibm.cic.common.core.preferences.searchForUpdates'/>
      

    We can find more details on silent preference keys in the IBM Installation Manager product documentation.

  • To install more than one instance of an offering, we must make the profile ID of each additional instance unique. For example:

      <offering profile='WebSphere Liberty - Another User's WAS Liberty ND' 
          features='' id='com.ibm.websphere.liberty.ND'/>

    This must be changed in both places that specify the profile ID in the response file.

  • To add the optional embeddable EJB container and JPA client feature (embeddablecontainer), add the feature in the offering. For example:

      <offering id='com.ibm.websphere.liberty.ND' 
        profile='WebSphere Liberty'
        features='embeddablecontainer' installFixes='none'/>

Here are some examples of changes that you could make to manipulate this response file to perform alternative actions.

  • To alter the location of the installation, simply change the installation location. For example: Replace

      <profile id='WebSphere Liberty' installLocation='/QIBM/ProdData/WebSphere/Liberty/ND'>

    with

      <profile id='WebSphere Liberty' installLocation='/home/user/IBM/WebSphere/Liberty/Server'>

  • To install from a local repository instead of the live remote repository, replace the repository location. For example: Replace

      <repository location='http://www.ibm.com/software/repositorymanager/com.ibm.websphere.liberty.ND'/>

    with

      <repository location='/home/user/repositories/WAS/local-repositories'/>