Stop Cluster

Download

Stop Cluster sample script for Liberty Collectives

Stop Cluster sample script for Liberty Collectives

Description

In IBM WebSphere Application Server Network Deployment Version 8.5.5, Liberty profile has introduced the Liberty collective feature. Refer to information about collectives in the IBM WebSphere Application Server Version 8.5.5 information center for more specifics.

The stopCluster.py sample demonstrates how to call the ClusterManager MBean from a Jython script to stop a cluster.

  • The ClusterManager MBean operation used:
    • stopCluster

stopCluster.py script

The stopCluster sample script demonstrates how to stop a static cluster with the given cluster name. A connection is made to the collective controller located at the given host and port, and the request to stop the cluster is passed to the ClusterManager MBean.

This ClusterManager MBean stop operation requires remote execution and access (RXA). Before running this sample script, ensure the target system(s) are configured for remote access. For more information on the remote execution and access requirements and setup, refer to Requirements for using Remote Execution and Access (RXA) in the information center.

Instructions

Required parameters

--clusterName The name of the cluster to stop.
--truststore The path to the truststore to be used when establishing a connection to the collective controller.
--truststorePassword The password for the truststore specified by the --truststore parameter.
--host The host name where the collective controller is running.
--port The https port where the collective controller is listening.
--user The user name to use when connecting to the collective controller.
--password The password to use when connecting to the collective controller.

Optional parameters

--help Displays help text.
--debug Displays additional details when an error occurs.

Sample use and resulting messages


>> jython stopCluster.py --clusterName=defaultCluster
   --host=localhost
   --port=9443
   --user=admin
   --password=password
   --truststore=D:\wlp\usr\servers\controller\resources\security\key.jks
   --truststorePassword=tsPassword

Connecting to the server...
Successfully connected to the server "localhost:9443"
localhost,D:/wlp/usr,member1 stopped, RC=0
localhost,D:/wlp/usr,member2 stopped, RC=0

	  

Notes

The following additional sample scripts provide shared code which is used by this sample:

  • wlp_arguments.py
  • wlp_cluster.py