738 lines
31 KiB
HTML
738 lines
31 KiB
HTML
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||
|
<html>
|
||
|
<head>
|
||
|
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||
|
<LINK rel="stylesheet" type="text/css" href="../../../rzahg/ic.css">
|
||
|
|
||
|
<title>The AdminConfig object for scripted administration</title>
|
||
|
</head>
|
||
|
|
||
|
<BODY>
|
||
|
<!-- Java sync-link -->
|
||
|
<SCRIPT LANGUAGE="Javascript" SRC="../../../rzahg/synch.js" TYPE="text/javascript"></SCRIPT>
|
||
|
|
||
|
<h5><a name="wsaobjadmcfg"></a>The AdminConfig object for scripted administration</h5>
|
||
|
|
||
|
<p>Use the AdminConfig object to invoke configuration commands and to create or change elements of the WebSphere Application Server - Express configuration.</p>
|
||
|
|
||
|
<p>You can start the scripting client without a running server, if you only want to use local operations. To run in local mode, use the -conntype NONE option to start the scripting client. You will receive a message that you are running in the local mode. If an application server is running, it is recommended that you do not run the AdminConfig tool in local mode.</p>
|
||
|
|
||
|
<p>The following public methods are available for the AdminConfig object:</p>
|
||
|
|
||
|
<p><strong>attributes</strong>
|
||
|
<br>Returns a list of the top level attributes for a given type.</p>
|
||
|
<p><strong>Note:</strong> The name of the object type that you input here is based on the XML configuration files and does not need to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: object type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig attributes ApplicationServer</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.attributes('ApplicationServer')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>"properties Property*" "serverSecurity ServerSecurity"
|
||
|
"server Server@" "id Long" "stateManagement StateManageable"
|
||
|
"name String" "moduleVisibility
|
||
|
EEnumLiteral(MODULE, COMPATIBILITY, SERVER, APPLICATION)"
|
||
|
"services Service*" "statisticsProvider StatisticsProvider"</pre>
|
||
|
|
||
|
<p><strong>checkin</strong>
|
||
|
<br>Checks a file in to the configuration repository. The file is described by the document URI.</p>
|
||
|
<p><strong>Note:</strong> This method only applies to deployment manager configurations.</p>
|
||
|
<p>Parameters: document URI, filename, opaque object</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig checkin cells/MyCell/Node/MyNode/serverindex.xml
|
||
|
/home/mydir/myfile $obj</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.checkin('cells/MyCell/Node/MyNode/serverindex.xml',
|
||
|
'c:\mydir\myfile', obj)</pre></li>
|
||
|
</ul>
|
||
|
<p>The document URI is relative to the root of the configuration repository (/QIBM/UserData/WebASE51/ASE/<em>instance</em>/config, where <em>instance</em> is the name of your application server instance). The file specified by the filename parameter is used as the source of the file to check in. The opaque object is an object that the extract command of the AdminConfig object returns by a prior call.</p>
|
||
|
|
||
|
<p><strong>contents</strong>
|
||
|
<br>Obtains information about object types.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files and does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: object type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig contents JDBCProvider</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.contents('JDBCProvider')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>{DataSource DataSource}
|
||
|
{WAS40DataSource WAS40DataSource}</pre>
|
||
|
|
||
|
<p><strong>convertToCluster</strong>
|
||
|
<br>Converts a server so that it is the first member of a new ServerCluster.</p>
|
||
|
<p>Arguments: server id, cluster name</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set serverid [$AdminConfig getid /Server:myServer/]
|
||
|
$AdminConfig convertToCluster $serverid myCluster</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>serverid = AdminConfig.getid('/Server:myServer/')
|
||
|
AdminConfig.convertToCluster(serverid, 'myCluster')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>myCluster(cells/mycell/clusters/myCluster:cluster.xml#ClusterMember_2</pre>
|
||
|
|
||
|
<p><strong>create</strong>
|
||
|
<br>Creates configuration objects.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files. It does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: type, parent ID, attributes</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set jdbc1 [$AdminConfig getid /JDBCProvider:jdbc1/]
|
||
|
$AdminConfig create DataSource $jdbc1 {{name ds1}}</pre></li>
|
||
|
<li>Jython with string attributes:
|
||
|
<pre>jdbc1 = AdminConfig.getid('/JDBCProvider:jdbc1/')
|
||
|
AdminConfig.create('DataSource', jdbc1, '[[name ds1]]')</pre></li>
|
||
|
<li>Jython with object attributes:
|
||
|
<pre>jdbc1 = AdminConfig.getid('/JDBCProvider:jdbc1/')
|
||
|
AdminConfig.create('DataSource', jdbc1, [['name', 'ds1']])</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>ds1(cells/mycell/nodes/DefaultNode/servers/server1:resources.xml#DataSource_6)</pre>
|
||
|
|
||
|
<p><strong>createClusterMember</strong>
|
||
|
<br>Creates a new server as a member of an existing cluster.</p>
|
||
|
<p>This method creates a new server object on the node that the node id argument specifies. This server is created as a new member of the existing cluster specified by the cluster id argument, and contains attributes specified in the member attributes argument. The server is created using the server template specified by the template id attribute, and contains the name specified by the memberName attribute. The memberName attribute is required.</p>
|
||
|
<p>Arguments: cluster id, node id, member attributes</p>
|
||
|
<p><strong>Note:</strong> The name of the object type that you specify here is the one based on the XML configuration files. It does not need to be the same name that the administrative console displays.</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set clid [$AdminConfig getid /ServerCluster:myCluster/]
|
||
|
set nodeid [$AdminConfig getid /Node:mynode/]
|
||
|
set template [$AdminConfig getid /Node:mynode/Server:myServer/]
|
||
|
$AdminConfig createClusterMember $clid $nodeid {{memberName newMem1} {weight 5
|
||
|
$template</pre></li>
|
||
|
<li>Jython with string attributes:
|
||
|
<pre>clid = AdminConfig.getid('/ServerCluster:myCluster/')
|
||
|
nodeid = AdminConfig.getid('/Node:mynode/')
|
||
|
AdminConfig.createClusterMember(clid, nodeid, '[[memberName newMem1] [weight 5]]')</pre></li>
|
||
|
<li>Jython with object attributes:
|
||
|
<pre>clid = AdminConfig.getid('/ServerCluster:myCluster/')
|
||
|
nodeid = AdminConfig.getid('/Node:mynode/')
|
||
|
AdminConfig.createClusterMember(clid, nodeid, [['memberName', 'newMem1'], ['weight', 5]])</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>myCluster(cells/mycell/clusters/myCluster:cluster.xml#ClusterMember_2)</pre>
|
||
|
|
||
|
<p><strong>createDocument</strong>
|
||
|
<br>Creates a new document in the configuration repository.</p>
|
||
|
<p>The documentURI argument names the document to create in the repository. The filename argument must be a valid local file name where the contents of the document exist.</p>
|
||
|
<p>Parameters: documentURI, filename</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig createDocument cells/mycell/myfile.xml /home/mydir/myfile</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.createDocument('cells/mycell/myfile.xml', 'c:\mydir\myfile')</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>createUsingTemplate</strong>
|
||
|
<br>Creates a type of object with the given parent, using a template.</p>
|
||
|
<p>Parameters: type, parent id, attributes, template ID</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set node [$AdminConfig getid /Node:mynode/]
|
||
|
set templ [$AdminConfig listTemplates JDBCProvider "DB2 JDBC Provider (XA)"]
|
||
|
$AdminConfig createUsingTemplate JDBCProvider $node {{name newdriver}} $templ</pre></li>
|
||
|
<li>Jython with string attributes:
|
||
|
<pre>node = AdminConfig.getid('/Node:mynode/')
|
||
|
templ = AdminConfig.listTemplates('JDBCProvider', "DB2 JDBC Provider (XA)")
|
||
|
AdminConfig.createUsingTemplate('JDBCProvider', node, '[[name newdriver]]', templ)</pre></li>
|
||
|
<li>Jython with object attributes:
|
||
|
<pre>node = AdminConfig.getid('/Node:mynode/')
|
||
|
templ = AdminConfig.listTemplates('JDBCProvider', "DB2 JDBC Provider (XA)")
|
||
|
AdminConfig.createUsingTemplate('JDBCProvider', node, [['name', 'newdriver']], templ)</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>defaults</strong>
|
||
|
<br>Displays the default values for attributes of a given type.</p>
|
||
|
<p>This method displays all of the possible attributes contained by an object of a specific type. If the attribute has a default value, this method also displays the type and default value for each attribute.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files. It does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig defaults TuningParams</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.defaults('TuningParams')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>
|
||
|
Attribute Type Default
|
||
|
usingMultiRowSchema Boolean false
|
||
|
maxInMemorySessionCount Integer 1000
|
||
|
allowOverflow Boolean true
|
||
|
scheduleInvalidation Boolean false
|
||
|
writeFrequency ENUM
|
||
|
writeInterval Integer 120
|
||
|
writeContents ENUM
|
||
|
invalidationTimeout Integer 30
|
||
|
invalidationSchedule InvalidationSchedule</pre>
|
||
|
|
||
|
<p><strong>deleteDocument</strong>
|
||
|
<br>Deletes a document from the configuration repository.</p>
|
||
|
<p>The documentURI argument names the document that will be deleted from the repository.</p>
|
||
|
<p>Parameters: documentURI</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig deleteDocument cells/mycell/myfile.xml</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.deleteDocument('cells/mycell/myfile.xml')</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>existsDocument</strong>
|
||
|
<br>Tests for the existence of a document in the configuration repository.</p>
|
||
|
<p>The documentURI argument names the document to test in the repository.</p>
|
||
|
<p>Parameters: documentURI</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig existsDocument cells/mycell/myfile.xml</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.existsDocument('cells/mycell/myfile.xml')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>1</pre>
|
||
|
|
||
|
<p><strong>extract</strong>
|
||
|
<br>Extracts a configuration repository file described by document URI and places it in the file named by filename.</p>
|
||
|
<p>Note: This method only applies to deployment manager configurations.</p>
|
||
|
<p>Parameters: document URI, filename</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set obj [$AdminConfig extract cells/MyCell/Node/MyNode/serverindex.xml
|
||
|
/home/mydir/myfile]</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>obj = AdminConfig.extract('cells/MyCell/Node/MyNode/serverindex.xml', 'c:\mydir\myfile')</pre></li>
|
||
|
</ul>
|
||
|
<p>The document URI is relative to the root of the configuration repository (/QIBM/UserData/WebASE51/ASE/<em>instance</em>/config, where <em>instance</em> is the name of your application server instance). If the file specified by filename exists, the extracted file replaces it.</p>
|
||
|
|
||
|
<p><strong>getCrossDocumentValidationEnabled</strong>
|
||
|
<br>Returns a message with the current cross-document enablement setting.</p>
|
||
|
<p>This method returns true if cross-document validation is enabled.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig getCrossDocumentValidationEnabled</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.getCrossDocumentValidationEnabled()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WASX7188I: Cross-document validation enablement set to true</pre>
|
||
|
|
||
|
<p><strong>getid</strong>
|
||
|
<br>Returns the configuration id of an object.</p>
|
||
|
<p>Parameters: containment path</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig getid /Cell:testcell/Node:testNode/JDBCProvider:Db2JdbcDriver/</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.getid('/Cell:testcell/Node:testNode/JDBCProvider:Db2JdbcDriver/')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>Db2JdbcDriver(cells/testcell/nodes/testnode/resources.xml#JDBCProvider_1)</pre>
|
||
|
|
||
|
<p><strong>getObjectName</strong>
|
||
|
<br>Returns a string version of the object name for the corresponding running MBean.</p>
|
||
|
<p>This method returns an empty string if there is no corresponding running MBean.</p>
|
||
|
<p>Parameters: configuration id</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set server [$AdminConfig getid /Node:mynode/Server:server1/]
|
||
|
$AdminConfig getObjectName $server</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>server = AdminConfig.getid('/Node:mynode/Server:server1/')
|
||
|
AdminConfig.getObjectName(server)</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WebSphere:cell=mycell,
|
||
|
name=server1,mbeanIdentifier=cells/mycell/nodes/mynode/servers/
|
||
|
server1/server.xml#Server_1,type=Server,node=mynode,process=server1,
|
||
|
processType=UnManagedProcess</pre>
|
||
|
|
||
|
<p><strong>getSaveMode</strong>
|
||
|
<br>Returns the mode used when you invoke a save command.</p>
|
||
|
<p>Possible values include the following:</p>
|
||
|
<ul>
|
||
|
<li>overwriteOnConflict - saves changes even if they conflict with other configuration changes </li>
|
||
|
<li>rollbackOnConflict - causes a save operation to fail if changes conflict with other configuration changes. This value is the default. </li>
|
||
|
</ul>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig getSaveMode</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.getSaveMode()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>rollbackOnConflict</pre>
|
||
|
|
||
|
<p><strong>getValidationLevel</strong>
|
||
|
<br>Returns the validation used when files are extracted from the repository.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig getValidationLevel</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.getValidationLevel()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WASX7189I: Validation level set to HIGH</pre>
|
||
|
|
||
|
<p><strong>getValidationSeverityResult</strong>
|
||
|
<br>Returns the number of validation messages with the given severity from the most recent validation.</p>
|
||
|
<p>Parameters: severity</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig getValidationSeverityResult 1</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.getValidationSeverityResult(1)</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>16</pre>
|
||
|
|
||
|
<p><strong>hasChanges</strong>
|
||
|
<br>Returns true if unsaved configuration changes exist.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig hasChanges</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.hasChanges()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>1</pre>
|
||
|
|
||
|
<p><strong>help</strong>
|
||
|
<br>Displays static help information for the AdminConfig object.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig help</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.help()</pre></li>
|
||
|
</ul>
|
||
|
<p>Output:</p>
|
||
|
<pre>WASX7053I: The AdminConfig object communicates with the
|
||
|
Config Service in a WebSphere server to manipulate configuration data
|
||
|
for a WebSphere installation. AdminConfig has commands to list, create,
|
||
|
remove, display, and modify configuration data, as well as commands to
|
||
|
display information about configuration data types.
|
||
|
|
||
|
Most of the commands supported by AdminConfig operate in two modes:
|
||
|
the default mode is one in which AdminConfig communicates with the
|
||
|
WebSphere server 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 AdminConfig; more detailed
|
||
|
information about each of these commands is available by using the
|
||
|
"help" command of AdminConfig and supplying the name of the command
|
||
|
as an argument.
|
||
|
|
||
|
attributes Show the attributes for a given type
|
||
|
checkin Check a file into the the config repository.
|
||
|
convertToCluster
|
||
|
converts a server to be the first member of a
|
||
|
new ServerCluster
|
||
|
create Creates a configuration object, given a type, a parent, and
|
||
|
a list of attributes, and optionally an attribute name for the
|
||
|
new object
|
||
|
createClusterMember
|
||
|
Creates a new server that is a member of an
|
||
|
existing cluster.
|
||
|
createDocument Creates a new document in the config repository.
|
||
|
installResourceAdapter
|
||
|
Installs a J2C resource adapter with the given rar
|
||
|
file name and an option string in the node.
|
||
|
createUsingTemplate
|
||
|
Creates an object using a particular template type.
|
||
|
defaults Displays the default values for attributes of a given type.
|
||
|
deleteDocument Deletes a document from the config repository.
|
||
|
existsDocument Tests for the existence of a document in the config repository.
|
||
|
extract Extract a file from the config repository.
|
||
|
getCrossDocumentValidationEnabled
|
||
|
Returns true if cross-document validation is enabled.
|
||
|
getid Show the configId of an object, given a string version of
|
||
|
its containment
|
||
|
getObjectName Given a config id, return a string version of the ObjectName
|
||
|
for the corresponding running MBean, if any.
|
||
|
getSaveMode Returns the mode used when "save" is invoked
|
||
|
getValidationLevel
|
||
|
Returns the validation used when files are extracted from the
|
||
|
repository.
|
||
|
getValidationSeverityResult
|
||
|
Returns the number of messages of a given
|
||
|
severity from the most recent validation.
|
||
|
hasChanges Returns true if unsaved configuration changes exist
|
||
|
help Show help information
|
||
|
list Lists all configuration objects of a given type
|
||
|
listTemplates Lists all available configuration templates of a given
|
||
|
type.
|
||
|
modify Change specified attributes of a given configuration object
|
||
|
parents Show the objects which contain a given type
|
||
|
queryChanges Returns a list of unsaved files
|
||
|
remove Removes the specified configuration object
|
||
|
required Displays the required attributes of a given type.
|
||
|
reset Discard unsaved configuration changes
|
||
|
save Commit unsaved changes to the configuration repository
|
||
|
setCrossDocumentValidationEnabled
|
||
|
Sets the cross-document validation enabled mode.
|
||
|
setSaveMode Changes the mode used when "save" is invoked
|
||
|
setValidationLevel
|
||
|
Sets the validation used when files are extracted from the
|
||
|
repository.
|
||
|
show Show the attributes of a given configuration object
|
||
|
showall Recursively show the attributes of a given configuration
|
||
|
object, and all the objects contained within each attribute.
|
||
|
showAttribute Displays only the value for the single attribute specified.
|
||
|
types Show the possible types for configuration
|
||
|
validate Invokes validation</pre>
|
||
|
|
||
|
<p><strong>installResourceAdapter</strong>
|
||
|
<br>Installs a J2C resource adapter with the given RAR file name and an option string in the node.</p>
|
||
|
<p>The RAR file name is the fully qualified file name that resides in the node that you specify. The valid options include the following:</p>
|
||
|
<ul>
|
||
|
<li>rar.name </li>
|
||
|
<li>rar.desc </li>
|
||
|
<li>rar.archivePath </li>
|
||
|
<li>rar.classpath </li>
|
||
|
<li>rar.nativePath </li>
|
||
|
</ul>
|
||
|
<p>All options are optional. The rar.name option is the name for the J2CResourceAdapter. If you do not specify this option, the display name in the rar deployment descriptor is used. If that is not specified, the RAR file name is used. The rar.desc option is a description of the J2CResourceAdapter. The rar.archivePath is the name of the path where the file is to be extracted. If you do not specify this option, the archive will be extracted to the $\{CONNECTOR_INSTALL_ROOT\} directory. The rar.classpath is the additional class path.</p>
|
||
|
<p>Parameters: rar file name, node, options</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig installResourceAdapter /rar/mine.rar {-rar.name myResourceAdapter
|
||
|
-rar.desc "My rar file"} mynode</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.installResourceAdapter('c:/rar/mine.rar',
|
||
|
'[-rar.name myResourceAdapter -rar.desc "My rar file"]', 'mynode')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>myResourceAdapter(cells/mycell/nodes/mynode:resources.xml#J2CResourceAdapter_1)</pre>
|
||
|
|
||
|
<p><strong>list</strong>
|
||
|
<br>Returns a list of objects of a given type, possibly scoped by a parent.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files and does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: object type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig list JDBCProvider</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.list('JDBCProvider')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>Db2JdbcDriver(cells/mycell/nodes/DefaultNode/resources.xml#JDBCProvider_1)
|
||
|
Db2JdbcDriver(cells/mycell/nodes/DefaultNode/servers/deploymentmgr/
|
||
|
resources.xml#JDBCProvider_1)
|
||
|
Db2JdbcDriver(cells/mycell/nodes/DefaultNode/servers/nodeAgent/
|
||
|
resources.xml#JDBCProvider_1)</pre>
|
||
|
|
||
|
<p><strong>listTemplates</strong>
|
||
|
<br>Displays a list of template object IDs.</p>
|
||
|
<p>Parameters: object type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig listTemplates JDBCProvider</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.listTemplates('JDBCProvider')</pre></li>
|
||
|
</ul>
|
||
|
<p>This example displays a list of all JDBCProvider templates available on the system.</p>
|
||
|
|
||
|
<p><strong>modify</strong>
|
||
|
<br>Supports modification of object attributes.</p>
|
||
|
<p>Parameters: object, attributes</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig modify
|
||
|
ConnFactory1(cells/mycell/nodes/DefaultNode/servers/deploymentmgr/resources.xml
|
||
|
#GenericJMSConnectionFactory_1) {{userID newID} {password newPW}}</pre></li>
|
||
|
<li>Jython with string attributes:
|
||
|
<pre>AdminConfig.modify('ConnFactory1(cells/mycell/nodes/DefaultNode/servers/
|
||
|
deploymentmgr/resources.xml#GenericJMSConnectionFactory_1)', '[[userID newID]
|
||
|
[password newPW]]')</pre></li>
|
||
|
<li>Jython with object attributes:
|
||
|
<pre>AdminConfig.modify('ConnFactory1(cells/mycell/nodes/DefaultNode/servers/
|
||
|
deploymentmgr/resources.xml#GenericJMSConnectionFactory_1)', [['userID', 'newID'],
|
||
|
['password', 'newPW']])</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>parents</strong>
|
||
|
<br>Obtains information about object types.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files and does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: object type</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig parents JDBCProvider</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.parents('JDBCProvider')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>Cell
|
||
|
Node
|
||
|
Server</pre>
|
||
|
|
||
|
<p><strong>queryChanges</strong>
|
||
|
<br>Returns a list of unsaved configuration files.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig queryChanges</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.queryChanges()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WASX7146I: The following configuration files contain unsaved changes:
|
||
|
cells/mycell/nodes/mynode/servers/server1/resources.xml</pre>
|
||
|
|
||
|
<p><strong>remove</strong>
|
||
|
<br>Removes a configuration object.</p>
|
||
|
<p>Parameters: object</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig remove ds1(cells/mycell/nodes/DefaultNode/servers/server1:
|
||
|
resources.xml#DataSource_6)</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.remove('ds1(cells/mycell/nodes/DefaultNode/servers/server1:
|
||
|
resources.xml#DataSource_6)')</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>required</strong>
|
||
|
<br>Displays the required attributes contained by an object of a certain type.</p>
|
||
|
<p>Note: The name of the object type that you input here is the one based on the XML configuration files. It does not have to be the same name that the administrative console displays.</p>
|
||
|
<p>Parameters: object</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig required URLProvider</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.required('URLProvider')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>Attribute Type
|
||
|
streamHandlerClassName String
|
||
|
protocol String</pre>
|
||
|
|
||
|
<p><strong>reset</strong>
|
||
|
<br>Resets the temporary workspace that holds updates to the configuration.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig reset</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.reset()</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>save</strong>
|
||
|
<br>Saves changes in the configuration repository.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig save</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.save()</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>setCrossDocumentValidationEnabled</strong>
|
||
|
<br>Sets the cross-document validation enabled mode. Values include true or false.</p>
|
||
|
<p>Parameters: flag</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig setCrossDocumentValidationEnabled true</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.setCrossDocumentValidationEnabled('true')</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>setSaveMode</strong>
|
||
|
<br>Allows you to toggle the behavior of the save command. The default is rollbackOnConflict. When a conflict is discovered while saving, the unsaved changes are not committed. The alternative is overwriteOnConflict which saves the changes to the configuration repository even if there are conflicts.</p>
|
||
|
<p>Parameters: mode</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig setSaveMode overwriteOnConflict</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.setSaveMode('overwriteOnConflict')</pre></li>
|
||
|
</ul>
|
||
|
|
||
|
<p><strong>setValidationLevel</strong>
|
||
|
<br>Sets the validation used when files are extracted from the repository.</p>
|
||
|
<p>There are five validation levels: none, low, medium, high, or highest.</p>
|
||
|
<p>Parameters: level</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig setValidationLevel high</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>AdminConfig.setValidationLevel('high')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WASX7189I: Validation level set to HIGH</pre>
|
||
|
|
||
|
<p><strong>show</strong>
|
||
|
<br>Returns the top level attributes of the given object.</p>
|
||
|
<p>Parameters: object, attributes</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig show Db2JdbcDriver(cells/mycell/nodes/DefaultNode/
|
||
|
resources.xm#JDBCProvider_1)</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre></pre></li>
|
||
|
</ul>
|
||
|
<p>Example output: for Jacl</p>
|
||
|
<pre>{name "Sample Datasource"}
|
||
|
{description "Data source for the Sample entity beans"} </pre>
|
||
|
|
||
|
<p><strong>showall</strong>
|
||
|
<br>Recursively shows the attributes of a given configuration object.</p>
|
||
|
<p>Parameters: object, attributes</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig showall "Default
|
||
|
Datasource(cells/mycell/nodes/DefaultNode/servers/server1:
|
||
|
resources.xml#DataSource_1)</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.show('Db2JdbcDriver
|
||
|
(cells/mycell/nodes/DefaultNode/resources.xm#JDBCProvider_1)')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output for Jacl:</p>
|
||
|
<pre>{authMechanismPreference BASIC_PASSWORD}
|
||
|
{category default}
|
||
|
{connectionPool {{agedTimeout 0}
|
||
|
{connectionTimeout 1000}
|
||
|
{maxConnections 30}
|
||
|
{minConnections 1}
|
||
|
{purgePolicy FailingConnectionOnly}
|
||
|
{reapTime 180}
|
||
|
{unusedTimeout 1800}}}
|
||
|
{datasourceHelperClassname com.ibm.websphere.rsadapter.CloudscapeDataStoreHelper}
|
||
|
{description "Datasource for the WebSphere Default Application"}
|
||
|
{jndiName DefaultDatasource}
|
||
|
{name "Default Datasource"}
|
||
|
{propertySet {{resourceProperties {{{description "Location of Cloudscape
|
||
|
default database."}
|
||
|
{name databaseName}
|
||
|
{type java.lang.String}
|
||
|
{value ${WAS_INSTALL_ROOT}/bin/DefaultDB}} {{name remoteDataSourceProtocol}
|
||
|
{type java.lang.String}
|
||
|
{value {}}} {{name shutdownDatabase}
|
||
|
{type java.lang.String}
|
||
|
{value {}}} {{name dataSourceName}
|
||
|
{type java.lang.String}
|
||
|
{value {}}} {{name description}
|
||
|
{type java.lang.String}
|
||
|
{value {}}} {{name connectionAttributes}
|
||
|
{type java.lang.String}
|
||
|
{value {}}} {{name createDatabase}
|
||
|
{type java.lang.String}
|
||
|
{value {}}}}}}}
|
||
|
{provider "Cloudscape JDBC
|
||
|
Driver(cells/pongo/nodes/pongo/servers/server1:resources.xml#JDBCProvider_1)"}
|
||
|
{relationalResourceAdapter "WebSphere Relational Resource
|
||
|
Adapter(cells/pongo/nodes/pongo/servers/server1:resources.xml#builtin_rra)"}
|
||
|
{statementCacheSize 0}</pre>
|
||
|
|
||
|
<p><strong>showAttribute</strong>
|
||
|
<br>Displays only the value for the single attribute that you specify.</p>
|
||
|
<p>The output of this command is different from the output of the show command when a single attribute is specified. The showAttribute command does not display a list that contains the attribute name and value. It only displays the attribute value.</p>
|
||
|
<p>Parameters: config id, attribute</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>set ns [$AdminConfig getid /Node:mynode/]
|
||
|
$AdminConfig showAttribute $n hostName</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>ns = AdminConfig.getid('/Node:mynode/')
|
||
|
print AdminConfig.showAttribute(ns, 'hostName')</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>mynode</pre>
|
||
|
|
||
|
<p><strong>types</strong>
|
||
|
<br>Returns a list of the configuration object types that you can manipulate.</p>
|
||
|
<p>Parameters: none</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig types</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.types()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>AdminService
|
||
|
Agent
|
||
|
ApplicationConfig
|
||
|
ApplicationDeployment
|
||
|
ApplicationServer
|
||
|
AuthMechanism
|
||
|
AuthenticationTarget
|
||
|
AuthorizationConfig
|
||
|
AuthorizationProvider
|
||
|
AuthorizationTableImpl
|
||
|
BackupCluster
|
||
|
CMPConnectionFactory
|
||
|
CORBAObjectNameSpaceBinding
|
||
|
Cell
|
||
|
CellManager
|
||
|
Classloader
|
||
|
ClusterMember
|
||
|
ClusteredTarget
|
||
|
CommonSecureInteropComponent</pre>
|
||
|
|
||
|
<p><strong>validate</strong>
|
||
|
<br>Invokes validation.</p>
|
||
|
<p>This command requests configuration validation results based on the files in your workspace, the value of the cross-document validation enabled flag, and the validation level setting. The scope of this request is the object named by the config id argument.</p>
|
||
|
<p>Parameters: config id</p>
|
||
|
<p>Example usage:</p>
|
||
|
<ul>
|
||
|
<li>Jacl:
|
||
|
<pre>$AdminConfig validate</pre></li>
|
||
|
<li>Jython:
|
||
|
<pre>print AdminConfig.validate()</pre></li>
|
||
|
</ul>
|
||
|
<p>Example output:</p>
|
||
|
<pre>WASX7193I: Validation results are logged in
|
||
|
/QIBM/UserData/WebASE51/ASE/myInstance/logs/wsadmin.valout:
|
||
|
Total number of messages: 16
|
||
|
WASX7194I: Number of messages of severity 1: 16</pre>
|
||
|
|
||
|
</body>
|
||
|
</html>
|