Artwork implying World Wide Web Architecture

Brain Dead Short (but useful) Jython Scripts

Part of the WebSphere Application Server v7.x Administration Series Series
Most recently modified on 2009-11-04
Back to home page Back to articles page WAS architecture articles page Script articles page .
See also these related articles:
Display WAS Variables

There are quite a few one line scripts that an administrator can use to obtain useful information about a WebSphere Application Server. Here are some useful one line scripts. To run them, type

wsadmin -lang jython -conntype NONE -c "print ****** "

Replace the ****** above with one of the one line scripts below

(If your deployment manager server is running, you can omit the -conntype NONE)

(If your default language is already set to Jython, you can omit the -lang jython)

script description
AdminTask.reportConfiguredPorts() Lists every server in your cell. Shows all the ports each server uses
AdminTask.reportConfigInconsistencies() Checks the configuation repository and reports any structural inconsistencies
AdminApp.list() Lists every application installed in your cell
AdminApp.view( 'appName' ) Replace appName with one of the names returned by AdminApp.list(). The name must be surrounded by quotes
AdminTask.generateSecConfigReport() Shows every setting related to security in your entire cell. Shows the current value of the setting. Shows the menu path through the Admin Console to that setting. The printout is a little confusing at first, but it is very useful once you get used to reading it.
AdminTask.createApplicationServer('DemoN01', '[-name classroom ]')

Creates a new application server called "classroom" in a node called "DemoN01"

The node must already exist and must already be federated into your cell.

Arthur Kevin McGrath


The author is an engineer with the consulting firm, Contract Engineers. He has consulted and lectured extensively since 1987 about the infrastructure that makes electronic commerce possible. His publications include Leading Practices for WebSphere Dynamic Process Edition V6.2 (SG24-7776-00) and Websphere Application Server Administration Using Jython (ISBN 0137009526), the definitive book on WAS scripting.

Photo of the author
To schedule a speaker at your location, write
To inquire about consulting for your company, write
To inquire about training for your company, write