[AIX Solaris HP-UX Linux Windows][z/OS]

Intelligent Management: middleware server management administrative tasks

You can use the Jython and Jacl scripting languages to manage middleware servers with the wsadmin tool. Use the commands and parameters in the MiddlewareServerManagement group.

getMiddlewareServerType

The getMiddlewareServerType command lists the middleware server types.

Target object

None.

Required parameters

-serverName
Specifies the name of the server for which you want to display the type. (String, required)
-nodeName
Specifies the node on which the server runs. (String, required)

Return value

The command returns a list of the middleware servers for the specified type.

Batch mode example usage

  • Using Jacl:
    $AdminTask getMiddlewareServerType {-serverName myserver -nodeName mynode}
  • Using Jython string:
    AdminTask.getMiddlewareServerType('[-serverName myserver -nodeName mynode]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask stopMiddlewareServer {-interactive}
  • Using Jython string:
    AdminTask.stopMiddlewareServer ('[-interactive]')

listForeignServerTypes

The listForeignServerTypes command lists all of the supported middleware server types, not including any middleware servers associated with Intelligent Management.

Target object

Return value

The command returns a list of middleware server types, for example:
PHP_SERVER
WASCE_SERVER
CUSTOMHTTP_SERVER
APACHE_SERVER
TOMCAT_SERVER
LIBERTY_SERVER
WEBLOGIC_SERVER 
JBOSS_SERVER 
WASAPP_SERVER

Batch mode example usage

  • Using Jacl:
    $AdminTask listForeignServerTypes
  • Using Jython string:
    AdminTask.listForeignServerTypes()

listMiddlewareServers

The listMiddlewareServers command lists the middleware servers and the path to the configuration file for the servers. If you do not pass node or middleware server type parameters, then all of the servers are displayed.

Target object

None.

Optional parameters

-middlewareServerType
Specifies the type of middleware server to list. The middleware server types include: TOMCAT_SERVER, LIBERTY_SERVER, PHP_SERVER, WEBLOGIC_SERVER, JBOSS_SERVER, WASCE_SERVER, APACHE_SERVER, and CUSTOMHTTP_SERVER.(String, optional)
-nodeName
Specifies the node for which to list the servers. (String, optional)

Return value

The command returns the list of the middleware servers for the type that you indicated. For example, you might see the following output:
nodeagent(cells/xdblade02b07/nodes/xdblade01b08/servers/nodeagent|server.xml)
WASCE_2.0.0.0_xdblade01b08_DS_2(cells/xdblade02b07/nodes/xdblade01b08/servers/WASCE_2.0.0.0_xdblade01b08_DS_2|server.xml)
WASCE_2.0.0.0_xdblade01b08_DS_1(cells/xdblade02b07/nodes/xdblade01b08/servers/WASCE_2.0.0.0_xdblade01b08_DS_1|server.xml)
WASCE_2.0.0.0_xdblade01b08_DS_4(cells/xdblade02b07/nodes/xdblade01b08/servers/WASCE_2.0.0.0_xdblade01b08_DS_4|server.xml)
frucg(cells/xdblade02b07/nodes/xdblade01b08/servers/frucg|server.xml)
WASCE_2.0.0.0_xdblade01b08_DD_1(cells/xdblade02b07/nodes/xdblade01b08/servers/WASCE_2.0.0.0_xdblade01b08_DD_1|server.xml)
dmgr(cells/xdblade02b07/nodes/xdblade02b07/servers/dmgr|server.xml)
middlewareagent(cells/xdblade02b07/nodes/thebe14/servers/middlewareagent|server.xml)
tttomcat_server(cells/xdblade02b07/nodes/thebe14/servers/tttomcat_server|server.xml)

Batch mode example usage

  • Using Jacl:
    $AdminTask listMiddlewareServers {-middlewareServerType TOMCAT_SERVER}
  • Using Jython string:
    AdminTask.listMiddlewareServers('[-middlewareServerType TOMCAT_SERVER]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask listMiddlewareServers
  • Using Jython string:
    AdminTask.listMiddlewareServers()

listMiddlewareServerTypes

The listMiddlewareServerTypes command lists all of the server types.

Target object

Return value

The command returns a list of all of the server types, for example:
APPLICATION_SERVER 
PHP_SERVER 
WASCE_SERVER 
CUSTOMHTTP_SERVER 
APACHE_SERVER 
TOMCAT_SERVER 
LIBERTY_SERVER
WEBLOGIC_SERVER 
ONDEMAND_ROUTER 
PROXY_SERVER 
WEB_SERVER 
JBOSS_SERVER 
WASAPP_SERVER 
GENERIC_SERVER

Batch mode example usage

  • Using Jacl:
    $AdminTask listMiddlewareServerTypes
  • Using Jython string:
    AdminTask.listMiddlewareServerTypes

Interactive mode example usage

listWASServerTypes

The listWASServerTypes command lists only the server types that are associated with WebSphere® Application Server.

Target object

Return value

The command returns a list of server types, for example:
APPLICATION_SERVER 
ONDEMAND_ROUTER 
PROXY_SERVER 
WEB_SERVER 
GENERIC_SERVER

Batch mode example usage

  • Using Jacl:
    $AdminTask listWASServerTypes
  • Using Jython string:
    AdminTask.listWASServerTypes()

modifyForeignServerProperty

The modifyForeignServerProperty command modifies a property on a middleware server.

Target object

None.

Required parameters

-serverName
Specifies the name of the server. (String, required)
-nodeName
Specifies the name of the node. (String, required)
-propKey
Specifies the property key that is associated with the server.xml file. (String, required)
-propValue
Specifies the property value that you want to set in the server.xml file. (String, required)

Return value

The command returns

Batch mode example usage

  • Using Jacl:
    $AdminTask modifyForeignServerProperty {-serverName WASCE_2.0.0.0_xdblade01b08_DS_4 -nodeName xdblade01b08 
    -propKey port -propValue 9090 }
  • Using Jython string:
    AdminTask.modifyForeignServerProperty('[-serverName WASCE_2.0.0.0_xdblade01b08_DS_4 -nodeName xdblade01b08
     -propKey port -propValue 9090]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask modifyForeignServerProperty {-interactive}
  • Using Jython string:
    AdminTask.modifyForeignServerProperty('[-interactive]')

showMiddlewareServerInfo

The showMiddlewareServerInfo command displays a list of properties for the middleware server.

Return value

The command returns

Required parameters

server_name(path_to_configuration_file|configuration_file_name)
This parameter determines the server for which you want to display the information. For example, you might use the following value for this parameter:
odr2(cells/SVT61/nodes/oberon04/servers/odr2|server.xml)
You can determine the value of the path_to_configuration_file variable and the configuration_file_name value by running the listMiddlewareServers command. You can use the output of that command as the parameter value.

Batch mode example usage

  • Using Jacl:
    $AdminTask showMiddlewareServerInfo odr2(cells/SVT61/nodes/oberon04/servers/odr2|server.xml)
  • Using Jython string:
    AdminTask.showMiddlewareServerInfo('odr2(cells/SVT61/nodes/oberon04/servers/odr2|server.xml)')

Interactive mode example usage

  • Using Jacl:
    $AdminTask showMiddlewareServerInfo {-interactive}
  • Using Jython string:
    AdminTask.showMiddlewareServerInfo('[-interactive]')

Example output

{cell SVT61}
{serverMiddlewareType ONDEMAND_ROUTER}
{com.ibm.websphere.baseProductVersion 6.1.0.11}
{node oberon04}
{server odr2}

startMiddlewareServer

The startMiddlewareServer command starts a specified middleware server.

Target object

None.

Required parameters

-serverName
Specifies the name of the server to start. (String, required)
-nodeName
Specifies the node on which the server that you want to start runs. (String, required)

Return value

The command returns

Batch mode example usage

  • Using Jacl:
    $AdminTask.startMiddlewareServer('[-serverName myserver -nodeName mynode]')
  • Using Jython string:
    AdminTask.startMiddlewareServer('[-serverName myserver -nodeName mynode]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask startMiddlewareServer{-interactive}
  • Using Jython string:
    AdminTask.startMiddlewareServer('[-interactive]')

stopMiddlewareServer

The stopMiddlewareServer command stops the specified middleware server.

Target object

None.

Required parameters

-serverName
Specifies the name of the middleware server to stop. (String, required)
-nodeName
Specifies the node on which the server that you want to stop runs. (String, required)

Batch mode example usage

  • Using Jacl:
    $AdminTask.stopMiddlewareServer('[-serverName myserver -nodeName  mynode]')
  • Using Jython string:
    AdminTask.stopMiddlewareServer('[-serverName myserver -nodeName mynode]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask stopMiddlewareServer {-interactive}
  • Using Jython string:
    AdminTask.stopMiddlewareServer ('[-interactive]')

executeMiddlewareServerOperation

The executeMiddlewareServerOperation command runs an existing server operation on a specified server.

Target object

None.

Required parameters

-serverName
Specifies the name of the server on which to run the server operation. (String, required)
-nodeName
Specifies the name of the node on which the specified server runs. (String, required)
-operation
Specifies the name of the server operation that you want to run on the server. (String, required)

Return value

The command returns a status message for the server operation, for example:
CWMWS0420I: Start completed for middleware server "WASCE_2.0.0.0_xdblade01b08_DS_4" 
on node "xdblade01b08"

Batch mode example usage

  • Using Jacl:
    $AdminTask executeMiddlewareServerOperation {-serverName WASCE_2.0.0.0_xdblade01b08_DS_4 
    -nodeName xdblade01b08 -operation start }
  • Using Jython string:
    AdminTask.executeMiddlewareServerOperation('[-serverName WASCE_2.0.0.0_xdblade01b08_DS_4 
    -nodeName xdblade01b08 -operation start]')

Interactive mode example usage

  • Using Jacl:
    $AdminTask executeMiddlewareServerOperation {-interactive}
  • Using Jython string:
    AdminTask.executeMiddlewareServerOperation('[-interactive]')