Stopping clusters using scripting

Use scripting and the wsadmin tool to stop a cluster.

Before you begin

Before starting this task, the wsadmin tool must be running. See the Starting the wsadmin scripting client article for more information.

About this task

Perform the following steps to stop a cluster:

Procedure

  1. 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 cluster
    This command returns the Cluster MBean.
    Example output:
    WebSphere:cell=mycell,name=cluster1,mbeanIdentifier=Cluster,type=Cluster,process=cluster1
    
  2. 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.



In this information ...


IBM Redbooks, demos, education, and more

(Index)

Use IBM Suggests to retrieve related content from ibm.com and beyond, identified for your convenience.

This feature requires Internet access.

Task topic Task topic    

Terms and conditions for information centers | Feedback

Last updatedLast updated: Aug 31, 2013 1:23:07 AM CDT
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=pix&product=was-nd-dist&topic=txml_stopcluster
File name: txml_stopcluster.html