+

Search Tips   |   Advanced Search

managesdk command

The managesdk command provides the names of software development kits used by the product.

Use the managesdk command to:

The command file is located in the app_server_root/bin directory and app_client_root/bin directory.

(iSeries) The managesdk command provides function that replaces the enableJvm command. The enableJvm command is deprecated. Use the managesdk command, instead of the enableJvm command.

If we use the managesdk command in a federated cell, and enable an SDK on a node, the SDK is not found by the command unless the node agent is restarted.

(ZOS) If we install a new SDK onto an existing copy of WebSphere Application Server for z/OS, each application server node or management node must be restarted before we can use the SDK on that node. When the node is restarted, the postinstaller creates the required symbolic links from the configuration file system to the product file system containing the new SDK.

After installation, the WAS looks at the installed Java SDKs, and chooses the highest level of Java SDK installed and used as the default for commands of newly created profiles. With this initial setting in place, the managesdk command can be used to change to another SDK, if one is available.


Syntax

Use the following command syntax with the managesdk command:

managesdk -task [-parameter] [value]

The command-line tool validates that the requested task contains the required parameters and values. Parameters are not case-sensitive. However, values are case-sensitive. We must type values with the correct capitalization because the command-line tool does not validate the capitalization of the parameter values. Incorrect results can occur when the parameter value is not typed correctly.


Parameters

The following -task options are available for the managesdk command:

-help

Displays detailed information about the parameters or values of each managesdk task. The following example uses the help parameter with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -help
(iSeries)
app_server_root/bin/managesdk -help
(Windows)
app_server_root\bin\managesdk.bat -help

The output from the help option describes the required and optional parameters.

-listAvailable [-verbose]

Display a list of all SDK names available to the product installation. When the -verbose option is also specified, a list of properties for each SDK name also is displayed. The following example uses the -listAvailable -verbose parameters with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -listAvailable -verbose
(iSeries)
app_server_root/bin/managesdk -listAvailable -verbose
(Windows)
app_server_root\bin\managesdk.bat -listAvailable -verbose

The output is a list of all SDK names that the product installation can use, along with a list of the properties associated with each SDK name.

-listEnabledProfile [-profileName profile] [-verbose]

Display a list of all SDK names that a specified profile, and its node and servers, is configured to use. When the -verbose option is also specified, a list of properties for each SDK name also is displayed. The following example uses the -listEnabledProfile -profileName and -verbose parameters with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -listEnabledProfile -profileName AppSrv02 -verbose
(iSeries)
app_server_root/bin/managesdk -listEnabledProfile -profileName AppSrv02 -verbose
(Windows)
app_server_root\bin\managesdk.bat -listEnabledProfile -profileName AppSrv02 -verbose

The output is a list of all SDK names that the specified profile can use, along with a list of the properties associated with each SDK name.

-listEnabledProfileAll [-verbose]

Display a list of all profiles in an installation and the SDK names that each profile, and its node and servers, is configured to use. When the -verbose option is also specified, a list of properties for each SDK name also is displayed. The following example uses the -listEnabledProfileAll and -verbose parameters with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -listEnabledProfileAll -verbose
(iSeries)
app_server_root/bin/managesdk -listEnabledProfileAll -verbose
(Windows)
app_server_root\bin\managesdk.bat -listEnabledProfileAll -verbose

The output is a list of all profiles in a product installation with all SDK names that each profile can use, along with a list of the properties associated with each SDK name.

-enableProfile [-profileName profile] [-sdkname sdkName] [-enableServers] [-user user_name] [-password password_value]

Enable a profile to use a specified SDK name. The -profileName parameter specifies the profile and the -sdkname parameter specifies the SDK name. The command enables the profile and the node-level default SDK of the profile to use the specified SDK name. Unless the -enableServers option is used, the command does not change server-level SDK settings. If the -enableServers option is used, all server-level SDK settings are cleared, enabling all servers to use the node-level default SDK.

The following conditions apply when the managesdk command is run:

  • If the profile is a federated node of a deployment manager, the deployment manager must be running when the managesdk command attempts to update the profile.

  • If the profile is a stand-alone application server, stand-alone secure proxy server, job manager, administrative agent, or deployment manager, then the profile server (node) must not be running when the managesdk command attempts to update the profile. Stop the server before running the managesdk command.

  • When we enable the SDK for a node, run the managesdk command from the /bin directory of the product installation to which the node belongs or from the /bin directory of the profile containing the node we want to update.
  • A connection to the deployment manager must exist using a supported connector protocol in the following order of preference:

    1. SOAP
    2. Inter-Process Communications (IPC)
    3. RMI

    If the SOAP protocol is enabled, the managesdk command uses the SOAP protocol. If the SOAP protocol is not enabled but the IPC protocol is enabled, the command uses the IPC protocol. If both the SOAP and IPC protocols are not enabled, then the command uses the RMI protocol.

  • Provide the administrative user name and password with the managesdk command for each profile containing a federated node or deployment manager node in a cell with security enabled. If we do not specify the -user and -password parameters, the managesdk command might fail or stop processing. The topic on configuring security with scripting provides connector protocol-specific instructions on how to save user name and password values.

  • When we enable the SDK for a deployment manager, only the deployment manager server is enabled. None of the managed nodes of the deployment manager are enabled to use the specific SDK.

The following example uses -enableProfile, -profileName, -sdkname, and -enableServers with the managesdk command:

(UNIX)

app_server_root/bin/managesdk.sh -enableProfile -profileName AppSrv02 -sdkname 8.0_64 -enableServers
(iSeries)
app_server_root/bin/managesdk -enableProfile -profileName AppSrv02 -sdkname 8.0_64 -enableServers
(Windows)
app_server_root\bin\managesdk.bat -enableProfile -profileName AppSrv02 -sdkname 8.0_64 -enableServers
(ZOS)
app_server_root/bin/managesdk.sh -enableProfile -profileName AppSrv02 -sdkname 8.0_64 -enableServers

The output is a message that indicates whether the specified profile was successfully updated and is now enabled to use the specified SDK, or whether problems were encountered that prevented the profile from being successfully updated.

-enableProfileAll [-sdkname sdkName] [-enableServers] [-user user_name] [-password password_value]

Enable all profiles in an installation to use a specified SDK name. The -sdkname parameter specifies the SDK name. The command enables all profiles and the node-level default SDK of each profile to use the specified SDK name. Unless the -enableServers option is used, the command does not change server-level SDK settings. If the -enableServers option is used, all server-level SDK settings are cleared, enabling all servers to use the node-level default SDK.

The following conditions apply when the managesdk command is run:

  • If the profile is a federated node of a deployment manager, the deployment manager must be running when the managesdk command attempts to update the profile.

  • If the profile is a stand-alone application server, stand-alone secure proxy server, job manager, administrative agent, or deployment manager, then the profile server (node) must not be running when the managesdk command attempts to update the profile. Stop the server before running the managesdk command.

  • When we enable the SDK for a node, run the managesdk command from the /bin directory of the product installation to which the node belongs or from the /bin directory of the profile containing the node we want to update.
  • A connection to the deployment manager must exist using a supported connector protocol in the following order of preference:

    1. SOAP
    2. Inter-Process Communications (IPC)
    3. RMI

    If the SOAP protocol is enabled, the managesdk command uses the SOAP protocol. If the SOAP protocol is not enabled but the IPC protocol is enabled, the command uses the IPC protocol. If neither the SOAP nor the IPC protocol are enabled, then the command uses the RMI protocol.

  • Provide the administrative user name and password with the managesdk command for each profile containing a federated node or deployment manager node in a cell with security enabled. If we do not specify the -user and -password parameters, the managesdk command might fail or stop processing. The topic on configuring security with scripting provides connector protocol-specific instructions on how to save user name and password values.

    Do not use the -enableProfileAll option unless automatic prompting is disabled for SOAP, IPC, and RMI connections to the deployment managers of cells that have any federated node or deployment manager with security enabled. Automatic prompting causes the managesdk command to fail or stop processing.

  • When we enable the SDK for a deployment manager, only the deployment manager server is enabled. None of the managed nodes of the deployment manager are enabled to use the specific SDK.

The following example uses -enableProfileAll, -sdkname, and -enableServers with the managesdk command:

(UNIX)

app_server_root/bin/managesdk.sh -enableProfileAll -sdkname 8.0_64 -enableServers
(iSeries)
app_server_root/bin/managesdk -enableProfileAll -sdkname 8.0_64 -enableServers
(Windows)
app_server_root\bin\managesdk.bat -enableProfileAll -sdkname 8.0_64 -enableServers
(ZOS)
app_server_root/bin/managesdk.sh -enableProfileAll -sdkname 8.0_64 -enableServers

The output is a message for each profile that indicates whether the profile was successfully updated and is now enabled to use the specified SDK, or whether problems were encountered that prevented the profile from being successfully updated.

-getNewProfileDefault [-verbose]

Display the SDK name configured for all profiles created with the manageprofiles command. When the -verbose option is also specified, properties information for the single SDK name also is displayed.

The following example uses the -getNewProfileDefault -verbose parameters with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -getNewProfileDefault -verbose
(iSeries)
app_server_root/bin/managesdk -getNewProfileDefault -verbose
(Windows)
app_server_root\bin\managesdk.bat -getNewProfileDefault -verbose

After the command runs, the new profile default SDK name is displayed.

-setNewProfileDefault [-sdkname sdkName]

Changes the SDK name configured for all profiles created with the manageprofiles command. The -sdkname parameter specifies the default SDK name to use. The sdkName value must be an SDK name enabled for the product installation.

The following example uses the -setNewProfileDefault -sdkname parameters with the managesdk command:

(UNIX)

app_server_root/bin/managesdk.sh -setNewProfileDefault -sdkname 8.0_64
(iSeries)
app_server_root/bin/managesdk -setNewProfileDefault -sdkname 8.0_64
(Windows)
app_server_root\bin\managesdk.bat -setNewProfileDefault -sdkname 8.0_64
(ZOS)
app_server_root/bin/managesdk.sh -setNewProfileDefault -sdkname 8.0_64

After the command runs, the new profile default SDK name is displayed.

-getCommandDefault [-verbose]

Display the SDK name that script commands in the app_server_root/bin, app_client_root/bin, or plugins_root/bin directory are enabled to use when no profile is specified by the command and when no profile is defaulted by the command. When the -verbose option is also specified, properties information for the single SDK name also is displayed.

The following example uses the -getCommandDefault -verbose parameters with the managesdk command:

(UNIX) (ZOS)

app_server_root/bin/managesdk.sh -getCommandDefault -verbose
(iSeries)
app_server_root/bin/managesdk -getCommandDefault -verbose
(Windows)
app_server_root\bin\managesdk.bat -getCommandDefault -verbose

-setCommandDefault [-sdkname sdkName]

Changes the SDK name that script commands in the app_server_root/bin, app_client_root/bin, or plugins_root/bin directory are enabled to use when no profile is specified by the command and when no profile is defaulted by the command. The -sdkname parameter specifies the SDK name to use for commands. The sdkName value must be an SDK name enabled for the product installation.

The following example uses the -getCommandDefault -sdkname parameters with the managesdk command:

(UNIX)

app_server_root/bin/managesdk.sh -setCommandDefault -sdkname 8.0_64
(iSeries)
app_server_root/bin/managesdk -setCommandDefault -sdkname 8.0_64
(Windows)
app_server_root\bin\managesdk.bat -setCommandDefault -sdkname 8.0_64
(ZOS)
app_server_root/bin/managesdk.sh -setCommandDefault -sdkname 8.0_64

The following special parameter options are available with task parameters of the managesdk command:

Using the same JVM for all tools and servers across the profile ensures consistent processing.bprac

-debug

Use this option with any -task parameter to enable additional debugging information in the command output.

-quiet

Use this option with any -task parameter to suppress most messages in the command output.

-sdkname

Use this option with a -set task parameter to specify an SDK name enabled for the product installation; for example:

  • (AIX) (HPUX) (iSeries) (Linux) (Solaris) (Windows) -sdkname 8.0_64

-verbose

Use this option with any -list or -get task parameter to provide additional information, such as SDK properties in the command output.

Usage scenario

The following examples demonstrate correct syntax when running the managesdk command:

managesdk -listAvailable -verbose
managesdk -listEnabledProfile -profileName AppSrv02 -verbose
managesdk -listEnabledProfileAll -verbose
managesdk -enableProfile -profileName AppSrv02 -sdkname 8.0_64 -enableServers
managesdk -enableProfileAll -sdkname 8.0_64 -enableServers
managesdk -getNewProfileDefault -verbose
managesdk -setNewProfileDefault -sdkname 8.0_64
managesdk -getCommandDefault -verbose
managesdk -setCommandDefault -sdkname 8.0_64

The following example demonstrates the sequence of commands to use to list available SDKs, change the default SDK to a v8.0 SDK and, if profiles exist already, enable the profiles to use the v8.0 SDK.

  1. Optionally, view a list of available SDK names for the product installation:
    managesdk -listAvailable
    

  2. Set the command default to the v8.0 SDK:
    managesdk -setCommandDefault -sdkname 8.0_64
    

  3. Set the new profile default to the v8.0 SDK:
    managesdk -setNewProfileDefault -sdkname 8.0_64
    

  4. If profiles already exist, enable the profiles to use the v8.0 SDK:
    managesdk -enableProfileAll -sdkname 8.0_64 -enableServers
    

    To change federated profiles in a Network Deployment installation, the deployment manager must be running. The managesdk command updates the master configuration repository. After the command runs, a synchronization operation must occur before the new SDK can be used for the federated profiles.

  • Use command-line tools
  • Configure security with scripting
  • (iSeries) Manually encoding passwords in properties files