+

Search Tips   |   Advanced Search

Install the v9.0 product using the job manager and command line

In a flexible management environment, we can use the job manager to install, update, and uninstall IBM WebSphere Application Server using the command line with a response file.

Before we install WAS using the job manager, ensure that we have WAS v9.0 installed on our primary machine.

(iSeries) The user profile must have *JOBCTL authorization in order to use centralized installation manager (CIM) on IBM i targets.

(ZOS) Note: CIM jobs to install, uninstall, and update Installation Manager are not supported on z/OS targets. We must first install Installation Manager on z/OS targets before using CIM manage offerings jobs.

To install WAS, use wsadmin to run the manageOfferings command. The manageOfferings command uses a response file and a security keyring. In the response file, we can set parameters for the directory in which to install the product on the target machine, specify where to store product data on the target machine, and specify the URL of the repository to download the product from. Depending on our security setup, we can also specify keyring credentials to log in to the product repository.

After the centralized installation manager successfully completes the installation process on a remote node, it then deletes the installation image files located in the temporary location specified during the installation process. If the installation is unsuccessful, the files remain in the temporary location for you to use to determine what caused the installation error. However, we can safely delete the files.

IBM Installation Manager 1.8.5 or later is required.


Tasks

  1. Start the job manager. For detailed instructions, see starting the job manager.

  2. Register a target host with the job manager.

    Use the wsadmin tool to run the registerHost command.

    • We can register the host with a private key; for example:

      • Use Jacl:

          $AdminTask registerHost {-host hostname -hostProps {{privateKeyFile filename} {username root }{saveSecurity true}}}

      • Use Jython:

          AdminTask.registerHost('[-host hostname -hostProps [[username user][privateKeyFile filename][saveSecurity true]]]')

    • We can register the host with a user name and password; for example:

      • Use Jacl:

          $AdminTask registerHost {-host hostname -hostProps { {password xxxxx} { username root } {saveSecurity true}}}

      • Use Jython:

          AdminTask.registerHost('[-host hostname -hostProps [[password xxxxx][username user] [saveSecurity true]]]')

  3. Optional: Test the connection to the targets on which we want to install the product. Before we install the product on a target machine, we can test the connection.

    • If we test the connection without specifying credentials, the test will use default to existing credentials; for example:

      • Use Jacl:

          $AdminTask submitJob {-jobType testConnection -targetList {hostname}}

      • Use Jython:

          AdminTask.submitJob('-jobType testConnection -targetList [hostname]')

    • We can submit the Test connection job with a username and password; for example:

      • Use Jacl:

          $AdminTask submitJob {-jobType testConnection -targetList {hostname} -username username -password password}

      • Use Jython:

          AdminTask.submitJob('-jobType testConnection -targetList [hostname] -username username -password password')

    • We can submit the Test connection job with a user name and private key file; for example:

      • Use Jacl:

          $AdminTask submitJob {-jobType testConnection -targetList {hostname} -username username -privateKeyFile private_key_filename}

      • Use Jython:

          AdminTask.submitJob('-jobType testConnection -targetList [hostname] -username username -privateKeyFile C:\temp\private_key_filename')

  4. Optionally run an Inventory job to see what is installed on the target machine.

    1. Submit an Inventory job with a user name and password.

      • Use Jacl:

          $AdminTask submitJob {-jobType inventory -targetList {hostname} -username username -password password}

      • Use Jython:

          AdminTask.submitJob('-jobType inventory -targetList [hostname] -username username -password password')

    2. Submit an Inventory job without a user name and password.

      • Use Jacl:

          $AdminTask submitJob {-jobType inventory -targetList {hostname}}

      • Use Jython:

          AdminTask.submitJob('-jobType inventory -targetList [hostname]')

  5. Optional: Install or update Installation Manager on the target machine.

    If we already have the correct version of Installation Manager on the target machine, we can proceed to the next step. See managing Installation Manager using the job manager.

  6. If we use SSH security, install your public key file.

    We can install the public key file using the same credentials as the job manager. This step does not apply to IBM i targets.

    1. Run the installSSHPublicKey admin task; for example:

      • Use Jacl:

          $AdminTask submitJob {-jobType installSSHPublicKey -targetList {target} -jobParams { {publicKeyFile keyfilepath} } -description "test installSSHPublicKey"}

      • Use Jython:

          AdminTask.submitJob ('-jobType installSSHPublicKey -targetList [target] -jobParams [[publicKeyFile keyfilepath]] -description "test installSSHPublicKey"')

  7. Set up a response file for the manageOfferings command.

    1. Create a response file. Create a response file using the Installation Manager. For more information, see creating a response file with Installation Manager.

    2. We can edit the response file to include information about your target machine.

    3. Use the response file to install any offering that is compatible with Installation Manager. For more information, see the Installation Manager information center.

    (Windows) Create a response file that specifies the offering profile parameter as WAS ND on Windows; for example:

      <?xml version="1.0" encoding="UTF-8"?> <agent-input acceptLicense='true' clean='true' temporary='true'> <server> <repository location='<MY REPOSITORY LOCATION>'/> </server> <profile installLocation='<LOCATION TO INSTALL PRODUCT ON TARGET MACHINE>' id='IBM WAS - ND'> <data key='cic.selector.nl' value='en'/> <data key='eclipseLocation' value='<LOCATION TO INSTALL PRODUCT DATA ON TARGET MACHINE>'/> <data key='user.select.64bit.image,com.ibm.websphere.ND.v90' value='false'/> </profile> <install modify='false'> <offering profile='IBM WAS - ND' features='core.feature' id='com.ibm.websphere.ND.v90' /> </install> <preference value='false' name='PassportAdvantageIsEnabled'/> <preference value='30' name='com.ibm.cic.common.core.preferences.connectTimeout'/> <preference value='0' name='com.ibm.cic.common.core.preferences.downloadAutoRetryCount'/> <preference value='C:\IBM\WebSphere\AppServer-Shared' name='com.ibm.cic.common.core.preferences.eclipseCache'/> <preference value='false' name='com.ibm.cic.common.core.preferences.http.disablePreemptiveAuthentication'/> <preference value='false' name='com.ibm.cic.common.core.preferences.keepFetchedFiles'/> <preference value='true' name='com.ibm.cic.common.core.preferences.preserveDownloadedArtifacts'/> <preference value='30' name='com.ibm.cic.common.core.preferences.readTimeout'/> <preference value='false' name='com.ibm.cic.common.core.preferences.searchForUpdates'/> <preference value='false' name='com.ibm.cic.common.core.preferences.ssl.nonsecureMode'/> <preference value='true' name='http.ntlm.auth.enableIntegrated.win32'/> <preference value='NTLM' name='http.ntlm.auth.kind'/> <preference value='true' name='offering.service.repositories.areUsed'/> </agent-input>

    1. Save the response file as filename.txt.

  8. Run the manageOfferings command. For the job to run successfully, specify acceptLicense TRUE.

    1. Open wsadmin from the job manager profile bin directory.

    2. Enter the manageOfferings command in wsadmin. For example:

      • Use Jacl:

          $AdminTask submitJob {-jobType manageOfferings -targetList hostname -username user -password ******* -jobParams {{responseFile <RESPONSE FILE LOCATION>} {acceptLicense TRUE} {IMPath <IM install location>} {keyringFile <key ring file location>} {keyringPassword pwd} }}

      • Use Jython:

          AdminTask.submitJob ('-jobType manageOfferings -targetList hostname -username user -password ******* -jobParams [[responseFile <RESPONSE FILE LOCATION>] [acceptLicense TRUE][IMPath <IM install location>] [keyringFile <key ring file location>] [keyringPassword pwd]]')

      The manageOfferings command pulls the response file that we created in this task and begins the product installation.

    The following parameter for this job is required:

    • responseFile: (Response file path name) This parameter contains the full path name to the offering response file on the job manager machine.

    The following parameters for this job are optional:

    1. IMPath: (IBM Installation Manager Path) This parameter contains the full path of the IBM installation manager on the remote machine. Use this parameter if we have more than one instance of Installation Manager on the remote machine. If we have only one instance of Installation Manager installed, we can leave this parameter empty because the job can find it. Specify whether the target machine has more than one instance of Installation Manager installed.
    2. keyringFile: (IBM Installation Manager key ring file): If the package repository requires a key ring file for authentication, specify the full path name of the key ring file on the job manager machine.
    3. keyringPassword: (Key ring password) If the key ring file is password protected, specify the key ring password.
    4. secureStorageFile: (Secure storage file) If we are using a secure file to store user credentials, specify the full path name of the secure storage file.
    5. masterPasswordFile: (Master password file) If we are using a master password file containing a master passphrase, such as "This text is the passphrase for a master password file, specify the full path name of the master password file.

  9. Optional: Run the collectFile and distributeFile administrative tasks.

    Optionally transfer files to or from the target machine and delete files on the target machine. For example, if the installation fails, we might want to transfer the log files from the target machine to understand why the job failed. When using these administrative tasks, we can specify wildcards in the filename.

    The destination must be a directory, it cannot be a file.

    • To collect a file from remote hosts:

      • Use Jacl:

          $AdminTask submitJob {-jobType collectFile -targetList hostname -jobParams {{source D:\\WAS85\\logs\\manageprofiles\\response.log} {destination log}}}

      • Use Jython:

          AdminTask.submitJob('-jobType collectFile -targetList hostname -jobParams [[source D:\\WAS85\\logs\\manageprofiles\\response.log] [destination log]')

    • To distribute a file to remote hosts:

      • Use Jacl:

          $AdminTask submitJob{-jobType distributeFile -targetList hostname -jobParams {{source test.txt}{destination D:\\temp\\test.txt} }}

      • Use Jython:

          AdminTask.submitJob('-jobType distributeFile -targetList hostname -jobParams [[source test.txt][destination D:\\temp\\test.txt] ]')

    • To delete a file on remote hosts:

      • Use Jacl:

          $AdminTask submitJob{-jobType removeFile -targetList hostname -jobParams {{location D:\\temp\\test.txt}}}

      • Use Jython:

          AdminTask.submitJob('-jobType removeFile -targetList hostname -jobParams [[location D:\\temp\\test.txt] ]')

  10. Create a profile for the newly installed product on the target machine.

    (ZOS) Restriction: This step does not apply to z/OS targets.

    Specify the following parameters:

    • targetList: The machine where we want to create a new profile
    • wasHome: The directory where we installed the product on the machine running job manager
    • responsefile: Enter the directory where you saved your response file. This text file provides the parameters and information of the profile to create.

    For example:

    • Use Jacl:

        $AdminTask submitJob {-jobType manageprofiles -targetList hostname -jobParams {{wasHome D:\\WAS70GA} {responseFile D:\\temp\\mp1.txt}}}

    • Use Jython:

        $AdminTask submitJob {-jobType manageprofiles -targetList hostname -jobParams {{wasHome D:\\WAS70GA} {responseFile D:\\temp\\mp1.txt}}}

We have installed the product on a target machine and created a profile using the job manager.


What to do next

Use the job manager, we can run any command or script on the target computer.

  • Submitting centralized installation manager jobs
  • Manage Installation Manager using the job manager