Example: Stopping a cluster using wsadmin
The following example stops a cluster:
- Identify the Cluster MBean and assign it to the cluster variable.
Using Jacl:
set cluster [$AdminControl completeObjectName cell=mycell,type=Cluster,name=cluster1,*
Using Jython:
cluster = AdminControl.completeObjectName('cell=mycell,type=Cluster,name=cluster1,*') print clusterThis command returns the Cluster MBean.
Example output:
WebSphere:cell=mycell,name=cluster1,mbeanIdentifier=Cluster,type=Cluster,process=cluster1
- Stop the cluster.
Using Jacl:
$AdminControl invoke $cluster stop
Using Jython:
AdminControl.invoke(cluster, 'stop')This command invokes the stop operation on the Cluster MBean.