Using the xsAdmin sample utility

With the xsAdmin sample utility, you can format and display textual information about your WebSphere® eXtreme Scale topology. The sample utility provides a method for parsing and discovering current deployment data, and can be used as a foundation for writing custom utilities.

Before you begin
You must have WebSphere eXtreme Scale installed.
About this task
You can use the xsAdmin sample utility to provide feedback on the current layout and specific state of the grid, such as map content. In this example, the layout of the grid in this task consists of a single grid, named ObjectGridA with one defined map, named MapA, belonging to the mapset, entitled MapSetA. This example demonstrates how you can display all active containers within a grid and print out filtered metrics regarding the map size of MapA. To see all possible command options, run the xsAdmin utility without any arguments or with the -help option.
  1. On the command line, set the JAVA_HOME environment variable.
    • [Unix] export JAVA_HOME=javaHome
    • [Windows] set JAVA_HOME=javaHome
  2. Navigate to the bin directory.
    cd objectGridRoot/bin
  3. Launch the xsAdmin utility.
    • To display the online help, run the following command:[Unix]
      xsadmin.sh
      [Windows]
      xsadmin.bat
      Take note on the required arguments section of the help message, because you must pass in only one of the listed options for the utility to work. If no -g or -m option is specified, the xsAdmin utility prints out information for every grid in the topology.
    • To display all online containers for a grid, run the following command:[Unix]
      xsadmin.sh -g ObjectGridA -m MapSetA -containers
      [Windows]
      xsadmin.bat -g ObjectGridA -m MapSetA -containers
      All container information is displayed. An example of the output follows:
       This administrative utility is provided as a sample only and is not to be
      considered a fully supported component of the WebSphere eXtreme Scale product
      Connecting to Catalog service at localhost:1099
      *** Show all online containers for grid - ObjectGridA & mapset - MapSetA
      Host: 192.168.0.186
        Container: server1_C-0, Server:server1, Zone:DefaultZone
          P:0 Primary
        Num containers matching = 1
        Total known containers = 1
        Total known hosts = 1
    • To display the number of entries in all the maps for a grid, run the following command:[Unix]
      xsadmin.sh -g ObjectGridA -m MapSetA -mapsizes -fm MapA
      [Windows]
      xsadmin.bat -g ObjectGridA -m MapSetA -mapsizes -fm MapA
      The size of the specified map is displayed. An example of the output follows:
      This administrative utility is provided as a sample only and is not to be
      considered a fully supported component of the WebSphere eXtreme Scale product
      
      Connecting to Catalog service at localhost:1099
      
      ****Displaying Results for Grid - ObjectGridA, MapSet - MapSetA*****
      
      
      *** Listing Maps for server1 ***
       Map Name: MapA  Partition #: 0  Map Size: 0  Shard Type: Primary
      Server Total: 0
    • To specify the JMX port for the catalog service, run the following command: The xsAdmin sample utility connects to the MBean server that is running on a catalog server. A catalog server can run in a standalone process, WebSphere Application Server process, or embedded within a custom application process. Use the -ch option to specify the catalog service host name, and the -p option to specify the catalog service naming port.
      [Unix]
      xsadmin.sh -g ObjectGridA -m MapSetA -mapsizes -fm MapA 
      		-ch CatalogMachine -p 6645
      [Windows]
      xsadmin.bat -g ObjectGridA -m MapSetA -mapsizes -fm MapA 
      		-ch CatalogMachine -p 6645
      The size of the specified map is displayed. An example of the output follows:
      This administrative utility is provided as a sample only and is not to be
      considered a fully supported component of the WebSphere eXtreme Scale product
      
      Connecting to Catalog service at CatalogMachine:6645
      
      *****Displaying Results for Grid - ObjectGridA, MapSet - MapSetA*****
      
      
      *** Listing Maps for server1 ***
       Map Name: MapA  Partition #: 0  Map Size: 0  Shard Type: Primary
      Server Total: 0
    • To connect to a catalog service hosted in a WebSphere Application Server process, perform the following steps:

      The -dmgr option is required when connecting to a catalog service hosted by any WebSphere Application Server process or cluster of processes. Use the -ch option to specify the host name if not localhost, and the -p option to override the catalog service bootstrap port, which uses the process BOOTSTRAP_ADDRESS. The -p option is only needed if the BOOTSTRAP_ADDRESS is not set to the default of 9809.

      Note: The standalone version of WebSphere eXtreme Scale cannot be used to connect to a catalog service hosted by a WebSphere Application Server process. Use the xsAdmin script included in the was_root/bin directory, which is available when the installing WebSphere eXtreme Scale on WebSphere Application Server or WebSphere Application Server Network Deployment.
      1. Navigate to the WebSphere Application Server bin directory:
        cd wasRoot/bin
      2. 2. Launch the xsAdmin utility using the following command:
        [Unix]
         xsadmin.sh -g ObjectGridA -m MapSetA -mapsizes -fm MapA -dmgr

        [Windows]
        xsadmin.bat -g ObjectGridA -m MapSetA -mapsizes -fm MapA -dmgr
      3. The size of the specified map is displayed.
      This administrative utility is provided as a sample only and is not to be
      considered a fully supported component of the WebSphere eXtreme Scale product
      
      Connecting to Catalog service at localhost:9809
      
      ****Displaying Results for Grid - ObjectGridA, MapSet - MapSetA*****
      
      
      *** Listing Maps for server1 ***
       Map Name: MapA  Partition #: 0  Map Size: 0  Shard Type: Primary
      Server Total: 0