Befehle für das Objekt "Help" mit wsadmin-Scripting

Sie können die Scripting-Sprachen Jython und Jacl verwenden, um mit dem Tool wsadmin allgemeine Hilfeinformationen und dynamische Onlineinformationen zu den derzeit aktiven MBeans zu suchen. Verwenden Sie das Objekt "Help" zur Unterstützung, wenn Sie Scripts mit dem Objekt AdminControl schreiben und ausführen.

AdminApp

Verwenden Sie den Befehl AdminApp, um eine Zusammenfassung zu jeder verfügbaren Methode für das Objekt "AdminApp" anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Keine.

Optionale Parameter

Keine.

Beispielausgabe

WASX7095I: The AdminApp object allows application objects to
be manipulated -- this includes installing, uninstalling, editing,
and listing.  Most of the commands supported by AdminApp operate in two
modes: the default mode is one in which AdminApp communicates with the
product to accomplish its tasks.  A local mode is also
possible, in which no server communication takes place.  The local
mode of operation is invoked by bringing up the scripting client with
no server connected using the command line "-conntype NONE" option or setting the 
"com.ibm.ws.scripting.connectionType=NONE" property in the wsadmin.properties.

The following commands are supported by AdminApp; more detailed information 
about each of these commands is available by using the "help" command of AdminApp and 
supplying the name of the command as an argument.

deleteUserAndGroupEntries  Deletes all the user/group information for all the roles and all 
the username/password information for RunAs roles for a given application.

edit Edit the properties of an application

editInteractive Edit the properties of an application interactively

export Export application to a file

exportDDL Export DDL from application to a directory

help Show help information

install Installs an application, given a file name and an option string.

installInteractive Installs an application in interactive mode, given a file name 
and an option string.

isAppReady Checks whether the application is ready to be run

list List all installed applications, either all applications or applications on a given target scope. 

listModules List the modules in a specified application

options Shows the options available, either for a given file, or in general.

publishWSDL Publish WSDL files for a given application

taskInfo Shows detailed information pertaining to a given installation task for a given file

uninstall Uninstalls an application, given an application name and an option string

updateAccessIDs Updates the user/group binding information with accessID from user 
registry for a given application

view View an application or module, given an application or module name

Beispiele

  • Mit Jacl:
    $Help AdminApp
  • Mit Jython:
    print Help.AdminApp()

AdminConfig

Verwenden Sie den Befehl AdminConfig, um eine Zusammenfassung zu jeder verfügbaren Methode für das Objekt "AdminConfig" anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Keine.

Optionale Parameter

Keine.

Beispielausgabe

WASX7053I: The following functions are 
supported by AdminConfig: 


create Creates a configuration object, 
given a type, a parent, and 

a list of attributes 


create Creates a configuration object, 
given a type, a parent, a 

list of attributes, and an attribute 
name for the new object 

remove Removes the specified configuration 
object 

list Lists all configuration objects of 
a given type 

list Lists all configuration objects of 
a given type, contained 

within the scope supplied 

show Show all the attributes of a given 
configuration object 

show Show specified attributes of a 
given configuration object 

modify Change specified attributes of a 
given configuration object 

getId Show the configId of an object, 
given a string version of 

its containment 

contents Show the objects which a given 
type contains 

parents Show the objects which contain 
a given type 

attributes Show the attributes for a 
given type 

types Show the possible types for 
configuration 

help Show help information 

Beispiele

  • Mit Jacl:
    $Help AdminConfig
  • Mit Jython:
    print Help.AdminConfig()

AdminControl

Verwenden Sie den Befehl AdminControl, um eine Zusammenfassung der help-Befehle und Methoden für den Aufruf eines Verwaltungsbefehls anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Keine.

Optionale Parameter

Keine.

Beispielausgabe

WASX7027I: The following functions are supported by AdminControl: 

getHost returns String representation of connected host 

getPort returns String representation of port in use 

getType returns String representation of connection type in use 

reconnect reconnects with server 

queryNames Given ObjectName and QueryExp, retrieves set of ObjectNames that match. 

queryNames Given String version of ObjectName, retrieves String of ObjectNames that match. 

getMBeanCount returns number of registered beans 

getDomainName returns "WebSphere" 

getDefaultDomain returns "WebSphere" 

getMBeanInfo Given ObjectName, returns MBeanInfo structure for MBean 

isInstanceOf Given ObjectName and class name, true if MBean is of that class 

isRegistered true if supplied ObjectName is registered 

isRegistered true if supplied String version of ObjectName is registered 

getAttribute Given ObjectName and name of attribute, returns value of attribute 

getAttribute Given String version of ObjectName and name of attribute, returns value of attribute 

getAttributes Given ObjectName and array of attribute names, returns AttributeList 

getAttributes Given String version of ObjectName and attribute names, 
returns String of name value pairs 

setAttribute Given ObjectName and Attribute object, set attribute for MBean specified 

setAttribute Given String version of ObjectName, attribute name and attribute value, 
set attribute for MBean specified 

setAttributes Given ObjectName and AttributeList object, set attributes for the MBean specified 

invoke Given ObjectName, name of method, array of parameters and signature, invoke method 
on MBean specified 

invoke Given String version of ObjectName, name of method, String version of parameter list, invoke 
method on MBean specified. 

invoke Given String version of ObjectName, name of method, String version of parameter list, and 
String version of array of signatures, invoke method on MBean specified. 

makeObjectName Return an ObjectName built with the given string 

completeObjectName Return a String version of an object name given a template name 

trace Set the wsadmin trace specification 

help Show help information 

Beispiele

  • Mit Jacl:
    $Help AdminControl
  • Mit Jython:
    print Help.AdminControl()

AdminTask

Verwenden Sie den Befehl AdminTask, um eine Zusammenfassung der help-Befehle und Methoden für den Aufruf eines Verwaltungsbefehls anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Keine.

Optionale Parameter

Keine.

Beispielausgabe

WASX8001I: The AdminTask object enables the available administrative commands. AdminTask commands 
operate in two modes: the default mode is one whichAdminTask communicates with the
 product to accomplish its task. A local mode 
is also available in which no server communication takes place. The local mode of operation is invoked by 
bringing up the scripting client using the command line "-conntype NONE" option or setting the
"com.ibm.ws.scripting.connectiontype=NONE" property in wsadmin.properties file.

The number of administrative commands varies and depends on your 
product installation. Use the following help
 commands to obtain a list of supported commands and their parameters:

help -commands		 					list all the administrative commands
help -commandGroups					list all the	administrative command groups
help commandName 						display detailed information for the specified command
help commandName stepName		display detailed information for the specified step belonging to the specified command
help commandGroupName				display detailed information for the specified command group

There are various flavors to invoke an administrative  command. They are

commandName invokes an administrative command that does not require any argument.

commandName targetObject invokes an admin command with the target object string, for example, 
the configuration object name of a resource adapter. The expected target object varies with the 
administrative command invoked. 

Use help command to get information on the target object of an administrative command.

commandName  options invokes an administrative command with the specified option strings. This invocation
 syntax is used to invoke an administrative command that does not require a target object. 

It is also used to enter interactive mode if "-interactive" mode is included in the options string.

commandName targetObject options invokes an administrative command with the specified target object 
and options strings. 

If "-interactive" is included in the options string, then interactive mode is entered. 
The target object and options strings vary depending on the admin command invoked. 
Use help command to get information on the target object and options.

Beispiele

  • Mit Jacl:
    $AdminTask help
  • Mit Jython:
    print AdminTask.help()

Alle

Verwenden Sie den Befehl all, um eine Zusammenfassung der Informationen, die die MBean definiert, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen an, der die gewünschte MBean darstellt. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

Name: WebSphere:cell=pongo,name=TraceService,mbeanIdentifier=cells/pongo/nodes/pongo/servers/server1/
server.xml#TraceService_1,type=TraceService,node=pongo,process=server1
Description: null
Class name: javax.management.modelmbean.RequiredModelMBean

Attribute                       Type                            Access
ringBufferSize                  int                             RW
traceSpecification              java.lang.String                RW

Operation
int getRingBufferSize()
void setRingBufferSize(int)
java.lang.String getTraceSpecification()
void setTraceState(java.lang.String)
void appendTraceString(java.lang.String)
void dumpRingBuffer(java.lang.String)
void clearRingBuffer()
[Ljava.lang.String; listAllRegisteredComponents()
[Ljava.lang.String; listAllRegisteredGroups()
[Ljava.lang.String; listComponentsInGroup
(java.lang.String)
[Lcom.ibm.websphere.ras.TraceElementState; 
getTracedComponents()
[Lcom.ibm.websphere.ras.TraceElementState; 
getTracedGroups()
java.lang.String getTraceSpecification(java.
lang.String)
void processDumpString(java.lang.String)
void checkTraceString(java.lang.String)
void setTraceOutputToFile(java.lang.String, 
int, int, java.lang.String)
void setTraceOutputToRingBuffer(int, java.
lang.String)
java.lang.String rolloverLogFileImmediate
(java.lang.String, java.lang.String)


Notifications
jmx.attribute.changed

Constructors

Beispiele

  • Mit Jacl:
    $Help all [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.all(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

attributes

Verwenden Sie den Befehl attributes, um eine Zusammenfassung aller Attribute, die die MBean definiert, nach Namen anzuzeigen. Wenn Sie den MBean-Namen angeben, zeigt der Befehl Informationen zu den Attributen, Operationen und Konstruktoren sowie die Beschreibung, Benachrichtigungen und den Klassennamen der angegebenen MBean an. Wenn Sie den MBean-Namen und den Attributnamen angeben, zeigt der Befehl Informationen zum angegebenen Attribut für die angegebene MBean an.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen an, der die gewünschte MBean darstellt. (Zeichenfolge)

Optionale Parameter

Attributname
Gibt das gewünschte Attribut an. (Zeichenfolge)

Beispielausgabe

Attribute Type Access 

ringBufferSize java.lang.Integer RW 

traceSpecification string RW 

Beispiele

  • Mit Jacl:
    $Help attributes [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.attributes(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

classname

Verwenden Sie den Befehl classname, um einen Klassennamen anzuzeigen, den die MBean definiert, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen an, der die gewünschte MBean darstellt. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

javax.management.modelmbean.RequiredModelMBean

Beispiele

  • Mit Jacl:
    $Help classname [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.classname(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

constructors

Verwenden Sie den Befehl constructors, um eine Zusammenfassung aller Konstruktoren, die die MBean definiert, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen an, der die gewünschte MBean darstellt. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

Constructors

Beispiele

  • Mit Jacl:
    $Help constructors [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.constructors(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

Beschreibung

Verwenden Sie den Befehl description, um eine Beschreibung, die die MBean definiert, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen an, der die gewünschte MBean darstellt. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

Managed object for overall server process.

Beispiele

  • Mit Jacl:
    $Help description [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.description(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

Hilfe

Verwenden Sie den Befehl help, um eine Zusammenfassung aller verfügbaren Methoden für das Objekt "Help" anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Keine.

Optionale Parameter

Keine.

Beispielausgabe

WASX7028I: The Help object has two purposes:

First, provide general help information for the objects supplied by the wsadmin tool 
for scripting: Help, AdminApp, AdminConfig, and AdminControl.

Second, provide a means to obtain interface information about the MBeans that run in 
the system.  For this purpose, a variety of commands are available to get 
information about the operations, attributes, and other interface information 
about particular MBeans.

The following commands are supported by Help; more detailed information about 
each of these commands is available by using the "help" command of Help and by 
supplying the name of the command as an argument.

attributes   		given an MBean, returns help for attributes
operations   		given an MBean, returns help for operations
constructors  	given an MBean, returns help for constructors
description   	given an MBean, returns help for description
notifications		given an MBean, returns help for notifications
classname     	given an MBean, returns help for class name
all          		given an MBean, returns help for all the previous
help         		returns this help text
AdminControl   	returns general help text for the AdminControl object
AdminConfig   	returns general help text for the AdminConfig object
AdminApp     		returns general help text for the AdminApp object
AdminTask    		returns general help text for the AdminTask object
wsadmin      		returns general help text for the wsadmin script launcher
message      		given a message ID, returns an explanation and a user action 

Beispiele

  • Mit Jacl:
    $Help help
  • Mit Jython:
    print Help.help()

das Kundenstamms

Verwenden Sie den Befehl message, um Informationen zu einer Nachrichten-ID anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

Nachrichten-ID
Gibt die Nachrichten-ID der gewünschten Nachricht an. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

Explanation: The container was unable to 
passivate an enterprise bean due to 
exception {2} 
User action: Take action based upon 
message in exception {2}

Beispiele

  • Mit Jacl:
    $Help message CNTR0005W
  • Mit Jython:
    print Help.message('CNTR0005W')

Benachrichtigungen

Verwenden Sie den Befehl notifications, um eine Zusammenfassung aller Benachrichtigungen, die die MBean definiert, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen der gewünschten MBean an. (Zeichenfolge)

Optionale Parameter

Keine.

Beispielausgabe

Notification 

websphere.messageEvent.audit 

websphere.messageEvent.fatal 

websphere.messageEvent.error 

websphere.seriousEvent.info 

websphere.messageEvent.warning 

jmx.attribute.changed 

Beispiele

  • Mit Jacl:
    $Help notifications [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
  • Mit Jython:
    print Help.notifications(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))

operations

Verwenden Sie den Befehl operations mit dem Parameter "MBean-Name", um eine Zusammenfassung aller Operationen, die die MBean definiert, nach Namen anzuzeigen. Geben Sie einen Wert für "MBean-Name" und "Operationsname" an, um die definierte Signatur der Operation für die MBean, nach Namen anzuzeigen.

Zielobjekt

Keine.

Erforderliche Parameter

MBean-Name
Gibt den Objektnamen der gewünschten MBean an. (Zeichenfolge)

Optionale Parameter

Operationsname
Gibt die gewünschte Operation an. (Zeichenfolge)

Beispielausgabe

Der Befehl gibt eine Ausgabe zurück, die dem folgenden Beispiel gleicht, wenn Sie nur den Parameter "MBean-Name" angeben:
Operation
int getRingBufferSize()
void setRingBufferSize(int)
java.lang.String getTraceSpecification()
void setTraceState(java.lang.String)
void appendTraceString(java.lang.String)
void dumpRingBuffer(java.lang.String)
void clearRingBuffer()
[Ljava.lang.String; listAllRegisteredComponents()
[Ljava.lang.String; listAllRegisteredGroups()
[Ljava.lang.String; listComponentsInGroup(java.lang.String)
[Lcom.ibm.websphere.ras.TraceElementState; getTracedComponents()
[Lcom.ibm.websphere.ras.TraceElementState; getTracedGroups()
java.lang.String getTraceSpecification(java.lang.String)
void processDumpString(java.lang.String)
void checkTraceString(java.lang.String)
void setTraceOutputToFile(java.lang.String, int, int, java.lang.String)
void setTraceOutputToRingBuffer(int, java.lang.String)
java.lang.String rolloverLogFileImmediate(java.lang.String, java.lang.String)
Der Befehl gibt eine Ausgabe zurück, die dem folgenden Beispiel gleicht, wenn Sie die Parameter "MBean-Name" und "Operationsname" angeben:
void processDumpString(string)

Description: Write the contents of the Ras 
services ring buffer to the specified file.

Parameters:

Type         string
Name         dumpString
Description  A String in the specified format to process or null.

Beispiele

  • Mit Jacl:
    $Help operations [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
    $Help operations [$AdminControl queryNames type=TraceService,process=server1,node=pongo,*]
     processDumpString
  • Mit Jython:
    print Help.operations(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'))
    print Help.operations(AdminControl.queryNames('type=TraceService,process=server1,node=pongo,*'), 
    'processDumpString')