WebLogic Server Command Reference
|
|
WebLogic Server provides several command-line utilities that you can use to automate the creation of domains, servers, and resources. The following sections describe combining shell scripts with the weblogic.Server, weblogic.Admin, and weblogic.Deployer commands to automate typical configuration tasks:
Alternatively, you use one of the following techniques to automate the configuration of a WebLogic Server domain based on your familiarity with the WebLogic Server Template Builder or Ant:
See "Creating Configuration Templates Using the Template Builder" in Creating WebLogic Configurations Using the Configuration Wizard and "Starting in Silent Mode" in Configuring WebLogic Platform.
Note: Although the documentation for the Template Builder and Configuration Wizard utilities is part of the WebLogic Platform documentation set, the utilities are installed with WebLogic Server and available for use even if you do not install WebLogic Platform.
weblogic.Server, weblogic.Admin, and weblogic.Deployer commands are functionally equivalent.
The section Sample Korn Shell Script provides a sample script for cloning and slightly modifying the MedRec domain.
To create and configure a domain such as the MedRec sample domain, use a shell script to:
See Creating a Domain.
weblogic.Admin commands that instantiate Administration MBeans. See:For more information about MBeans in WebLogic Server, see "Overview of WebLogic JMX Services" in Programming WebLogic Management Services with JMX.
All WebLogic Server commands require an SDK to be specified in the environment's PATH variable and a set of WebLogic Server classes to be specified in the CLASSPATH variable.
Use the following script to add an SDK to PATH variable and the WebLogic Server classes to the CLASSPATH variable:
WL_HOME\server\bin\setWLSEnv.cmd (on Windows) WL_HOME/server/bin/setWLSEnv.sh (on UNIX)
If you want to use JDBC resources to connect to a database, modify the environment as the database vendor requires. Usually this entails adding driver classes to the CLASSPATH variable and vendor-specific directories to the PATH variable. To set the environment that the sample Pointbase database requires as well as add an SDK to PATH variable and the WebLogic Server classes to the CLASSPATH variable, invoke the following script:
WL_HOME\samples\domains\medrec\setMedRecEnv.cmd (on Windows) WL_HOME/samples/domains/medrec/setMedRecEnv.sh (on UNIX)
To create a domain named mymedrec with an Administration Server named myMedRecServer that listens on port 8001:
java -Dweblogic.management.username=weblogic
-Dweblogic.management.password=weblogic
-Dweblogic.Domain=mymedrec
-Dweblogic.Name=myMedRecServer
-Dweblogic.ListenPort=8001
-Dweblogic.management.GenerateDefaultConfig=true
weblogic.Server
When you invoke the weblogic.Server class in a directory that does not contain a config.xml file, WebLogic Server creates and starts a domain with an Administration Server. See Default Behavior.
-Dweblogic.Domain option must match the name of the current directory.-Dweblogic.management.GenerateDefaultConfig=true prevents the weblogic.Server class from prompting you for confirmations.The commands in Listing 2-1 create JDBC resources in the mymedrec domain.
Listing 2-1 Creating JDBC Resources
# Create a JDBC Connection Pool for Applications
CREATE_POOL myMedRecPoolXA
driver="com.pointbase.xa.xaDataSource",
url=jdbc:pointbase:server://localhost:9093/demo,
props=user=medrec;password=medrec;
DatabaseName=jdbc:pointbase:server://localhost:9093/demo,maxCapacity=10
# Create a Transactional Data Source
CREATE -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
# Configure the Transactional Data Source
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property JNDIName "MedRecTxDataSource"
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property PoolName "myMedRecPoolXA"
# Create another JDBC Connection Pool for the JMS JDBC Store
CREATE_POOL myMedRecPool driver="com.pointbase.jdbc.jdbcUniversalDriver",
url=jdbc:pointbase:server://localhost:9093/demo,
props=user=medrec;password=medrec,
DatabaseName=jdbc:pointbase:server://localhost:9093/demo,maxCapacity=10
When invoked by the weblogic.Admin BATCHUPDATE command, the commands in Listing 2-1 do the following (see BATCHUPDATE):
The database listens on port 9093 and is named demo.
The CREATE_POOL command creates an MBean of type JDBCConnectionPool whose object name is mymedrec:Name=myMedRecPoolXA,Type=JDBCConnectionPool.
JDBCTxDataSourceMBean Administration MBean. The CREATE -mbean command creates an MBean and specifies the MBean's WebLogicObjectName. In this object name:
mymedrec: specifies the name of the WebLogic Server domain.Name=MedRecTxDataSource provides a unique name for the JDBC transactional data source you want to create.Type=JDBCTxDataSource specifies the type of MBean to create.JDBCTxDataSourceMBean that you instantiated. To see all attributes and legal values of the JDBCTxDataSourceMBean, refer to the Javadoc.
To create JDBC resources in the mymedrec domain:
mymedrec directory that you created in Creating a Domain. java weblogic.Admin -url localhost:7001 -username weblogic -password weblogic BATCHUPDATE -batchFile c:\myfile -batchCmdVerbose
where c:\myfile is the name of a text file that contains the commands in Listing 2-1.
See BATCHUPDATE.
The commands in Listing 2-2 create JMS resources in the mymedrec domain.
Listing 2-2 Creating JMS Resources
# Creating a JMS Connection Factory
CREATE -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
# Configuring the JMS Connection Factory
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property JNDIName "jms/MedRecQueueConnectionFactory"
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property XAServerEnabled "true"
#
# Creating and Configuring a JMS JDBC Store
CREATE -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
SET -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
-property ConnectionPool "mymedrec:Name=myMedRecPool,Type=JDBCConnectionPool"
SET -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
-property PrefixName "MedRec"
# Creating and Configuring a JMS Server
CREATE -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
SET -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
-property Store "mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore"
# Creating and Configuring a Queue
CREATE -mbean
mymedrec:JMSServer=MedRecJMSServer,Name=RegistrationQueue,Type=JMSQueue
SET -mbean
mymedrec:JMSServer=MedRecJMSServer,Name=RegistrationQueue,Type=JMSQueue
-property JNDIName "jms/REGISTRATION_MDB_QUEUE"
# Creating and Configuring an Additional Queue
CREATE -mbean mymedrec:JMSServer=MedRecJMSServer,Name=MailQueue,Type=JMSQueue
SET -mbean mymedrec:JMSServer=MedRecJMSServer,Name=MailQueue,Type=JMSQueue
-property JNDIName "jms/MAIL_MDB_QUEUE"
# Creating and Configuring an Additional Queue
CREATE -mbean mymedrec:JMSServer=MedRecJMSServer,Name=XMLQueue,Type=JMSQueue
SET -mbean mymedrec:JMSServer=MedRecJMSServer,Name=XMLQueue,Type=JMSQueue
-property JNDIName "jms/XML_UPLOAD_MDB_QUEUE"
When invoked by the weblogic.Admin BATCHUPDATE command, the commands do the following (see BATCHUPDATE):
The CREATE -mbean command creates an MBean and specifies the MBean's WebLogicObjectName. (See "JMS Configuration Namespace" in Programming WebLogic Management Services with JMX.) In this object name:
mymedrec: specifies the name of the WebLogic Server domain.Name=MedRecQueueFactory provides a unique name for the JMS connection factory you want to create. Type=JMSConnectionFactory specifies the type of MBean to create.JMSConnectionFactory that you instantiated. -mbean argument specifies the WebLogicObjectName of the JMSConnectionFactory that you instantiated.-property argument specifies an MBean attribute name and its value.To see all attributes and legal values of the JMSConnectionFactory, refer to the Javadoc.
JMSJDBCStoreMBean.The command that sets the value of the ConnectionPool attribute specifies the WebLogicObjectName of a JDBC connection pool because the JMSJDBCStoreMBean Javadoc indicates that the ConnectionPool attribute must be a JDBCConnectionPoolMBean object name:
public void setConnectionPool(JDBCConnectionPoolMBean connectionPool)
The command that sets the value of the Store attribute specifies the WebLogicObjectName of a JMS store because the JMSServerMBean Javadoc indicates that the Store attribute must be an object name of type JMSStoreMBean:
public void setStore(JMSStoreMBean store)
MBean.The queues are named RegistrationQueue, MailQueue and XMLQueue.
To see all attributes and legal values of the JMSQueueMBean, refer to the Javadoc.
The commands in Listing 2-3 add email capabilities to the MedRec applications in the mymedrec domain by creating and configuring a MailSessionMBean. You can save the commands in a text file and invoke them with the weblogic.Admin BATCHUPDATE command (see BATCHUPDATE).
Note: To see all attributes and legal values of the MailSessionMBean, refer to the Javadoc. For more information about the WebLogic Server mail service, see "Mail" in the Administration Console Online Help.
Listing 2-3 Creating Mail Resources
CREATE -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property JNDIName "mail/MedRecMailSession"
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property Properties "mail.user=joe;mail.host=mail.mycompany.com"
In a production environment, BEA recommends that you create one or more Managed Servers to host applications and resources. Use the Administration Server only to configure and manage the domain.
The commands in Listing 2-4 create and configure a Managed Server in the mymedrec domain.
Listing 2-4 Creating and Configuring Managed Servers
# Creating and Configuring a Server
CREATE -mbean mymedrec:Name=MedRecServer1,Type=Server
SET -mbean mymedrec:Name=MedRecServer1,Type=Server
-property ListenPort "8011"
# Targeting Resources to MedRecServer1
SET -mbean mymedrec:Name=MedRecPoolXA,Type=JDBCConnectionPool
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=myMedRecPoolXA,Type=JDBCConnectionPool
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
When invoked by the weblogic.Admin BATCHUPDATE command, the commands do the following (see BATCHUPDATE):
ListenPort attribute of myMedRecServer1's ServerMBean.Targets attribute of the resources' MBeans.For example, to make the myMedRecPoolXA JDBC connection pool available to myMedRecServer1, you set the Targets attribute of the myMedRecPoolXA's JDBCConnectionPoolMBean. The JDBCConnectionPoolMBean Javadoc indicates that the Targets attribute must be an object name of type ServerMBean:
public void setTargets(TargetMBean[] Targets)
ServerMBean is a subtype of TargetMBean. See Using weblogic.Admin Commands to Target Resources.
The commands in Listing 2-5, configure Machines and Node Manager properties in the mymedrec domain.
This is a common task for domains that contain multiple server instances. By configuring machines and Node Manager properties for a server, the server can be started and managed by a Node Manager. See "Overview of Node Manager" in Configuring and Managing WebLogic Server.
Listing 2-5 Configuring Machines and Node Manager Properties
# Create a Machine
CREATE -mbean mymedrec:Name=WLSHost,Type=Machine
SET -mbean mymedrec:Machine=WLSHost,Name=WLSHost,Type=NodeManager
-property ListenAddress WLSHost -property ListenPort 5560
# Assign the Machine to a Server
SET -mbean mymedrec:Name=myMedRecServer1,Type=Server
-property Machine "mymedrec:Name=WLSHost,Type=Machine"
When invoked by the weblogic.Admin BATCHUPDATE command, the commands do the following (see BATCHUPDATE):
The CREATE -mbean command creates an MBean and specifies the MBean's WebLogicObjectName. (See "Machines and Node Manager Configuration Namespace" in Programming WebLogic Management Services with JMX.) In this object name:
mymedrec: specifies the name of the WebLogic Server domain.Name=WLHost1 provides a unique name for the machine you want to create. By convention, the machine name reflects the name of the computer that the machine represents. See "Machines" in the Administration Console Online Help.Type=Machine specifies the type of MBean to create.NodeManagerMBean for the machine. When you create a MachineMBean instance, WebLogic Server also creates a NodeManagerMBean to specify the listen address, listen port, and security information that a server instance uses to communicate with a Node Manager running on a specific machine.The example commands set non-default values for the ListenAddress and ListenPort properties. In the NodeManagerMBean object name:
mymedrec: specifies the name of the WebLogic Server domain.Machine=WLSHost indicates that the NodeManagerMBean is a child of the WLSHost MachineMBean. (See "Machines and Node Manager Configuration Namespace" in Programming WebLogic Management Services with JMX.)Name=WLHost1 follows the WebLogic Server convention of having child objects reflect the object name of the parent.Type=NodeManager specifies the type of MBean to create.To see all attributes and legal values of the NodeManagerMBean, refer to the Javadoc.
Machine attribute of myMedRecServer1's ServerMBean. Assigning a machine to a server enables the server to be started by the machine's Node Manager.The ServerMBean Javadoc indicates that the Machine attribute must be an object name of type MachineMBean:
The weblogic.Deployer commands in Listing 2-6 deploy the sample MedRec applications in the mymedrec domain.
Listing 2-6 Deploying Applications
java weblogic.Deployer -url t3://localhost:8001 -username weblogic
-password weblogic -targets myMedRecServer1 -name MedRecEAR
-deployD:\bea\weblogic81\samples\server\medrec\dist\medrecEar
java weblogic.Deployer -url t3://localhost:8001 -username weblogic
-password weblogic -targets myMedRecServer1 -name PhysicianEAR
-deployD:\bea\weblogic81\samples\server\medrec\dist\physicianEar
java weblogic.Deployer -url t3://localhost:8001 -username weblogic
-password weblogic -targets myMedRecServer1 -name StartupEAR
-deployD:\bea\weblogic81\samples\server\medrec\dist\startupEar
weblogic.Deployer command does not provide an equivalent to the weblogic.Admin BATCHUPDATE command, so you must invoke java weblogic.Deployer separately for each application that you want to deploy.CLASSPATH environment variable. See Setting Up the Environment.localhost:8001).D:\bea\weblogic81\samples\server\medrec\src directory.-targets myMedRecServer1 argument. If the myMedRecServer1 server instance is active when you invoke the weblogic.Deployer command, deployment initiates immediately. Otherwise, deployment initiates when you start the myMedRecServer1 server instance.See "weblogic.Deployer Utility" in Deploying WebLogic Server Applications.
This section describes an example Korn shell script that creates and configures a domain as described in Using Command-Line Utilities to Clone the MedRec Domain: Main Steps.
To use the sample Korn shell script:
CreateDomain.sh.BEA recommends that you save this script in an empty directory. By default, the shell script creates a domain directory named.\mymedrec. That is, the mymedrec directory is a child of the directory from which you invoke the command.
ConfigDomain.txt and locate it in the same directory as CreateDomain.sh.weblogic.Admin CONNECT command.The CONNECT command connects to a WebLogic Server instance and returns two numbers representing the total time for each round trip and the average amount of time (in milliseconds) that each connection is maintained. See CONNECT.
weblogic.Admin BATCHUPDATE to configure resources.java -Dweblogic.Name=myMedRecServer1
-Dweblogic.management.server=http://localhost:8001 weblogic.Server & weblogic.Deployer commands described in Deploying Applications.Listing 2-7 Korn Shell Script for Recreating the MedRec Domain
#!/bin/sh
########################
# Defining Functions #
########################
# Wrapper function for weblogic.Admin
wladmin()
{
java weblogic.Admin -username $ADMINUSER -password $ADMINPASS `
-adminurl $ADMINHOST:$ASPORT $*
}
# This function waits for a server to boot, if server is running, sets
# SERVERSTATE var to "RUNNING", otherwise, "SHUTDOWN"
#
# Params:
# $1 Wait interval in seconds
# $2 Max wait period, in seconds
#
WaitForServer()
{
WAIT_INTERVAL=${1:-10}
MAX_WAIT=${2:-120}
CONNECTCMD="wladmin connect 1"
CONNECTRESPONSE=
CONNECTED=
let total_wait=0
while test "$CONNECTED" != "Connection" && test total_wait -lt MAX_WAIT
do
sleep 10
let "total_wait=$total_wait+$WAIT_INTERVAL"
echo Attempting to connect to server...
CONNECTRESPONSE="\Q$CONNECTCMD\Q"
CONNECTED="\Qecho $CONNECTRESPONSE | cut -d: -f1\Q"
echo "Response to connect command: $CONNECTRESPONSE"
done
# Set the status so the caller can check the result
if [ "$CONNECTED" == "Connection" ]; then
SERVERSTATE="RUNNING"
echo Connected to server!
else
SERVERSTATE="SHUTDOWN"
echo Could not connect to server
fi
}
# This function creates a new domain and starts the Administration
# Server.
#
CreateDomain() {
Echo "Starting server $SERVERNAME"
java -Dweblogic.management.GenerateDefaultConfig=true `
-Dweblogic.management.username=${ADMINUSER} `
-Dweblogic.management.password=${ADMINPASS} `
-Dweblogic.Domain=${DOMAIN} `
-Dweblogic.Name=${SERVERNAME} `
-Dweblogic.ListenPort=${ASPORT} `
weblogic.Server > ${SERVERNAME}.out 2>&1 &
WaitForServer 10 120
}
###########################
# Setting the Environment #
###########################
# Override values in the script with any
# values supplied from the command line.
if [ $# -gt 0 ]; then
echo Setting environment variables $*
export $*
fi
# Set script variables.
PROTOCOL=t3
ADMINUSER=${ADMINUSER:-weblogic}
ADMINPASS=${ADMINPASS:-weblogic}
ADMINHOST=${ADMINHOST:-localhost}
ASPORT=${ASPORT:-8001}
DOMAIN=${DOMAIN:-mymedrec}
DOMAINDIR=${DOMAINDIR:-$DOMAIN}
SERVERNAME=${SERVERNAME:-MedRecServer}
# Check for environment variables.
if [ -z "$WL_HOME" ]; then
echo "Need to set WL_HOME first!"
exit 1
fi
###########################
# Invoking the Functions #
###########################
# Check to see if server is runningConnected
SERVERSTATE="" # reset result of Wait function
WaitForServer 5 5
if [ "$SERVERSTATE" == "RUNNING" ]; then
echo "Server is already running on port $ASPORT!"
exit 1
fi
# Create the domain directory.
mkdir ${DOMAINDIR}
status=$?
if [ $status != 0 ]; then
echo "Could not create domain directory ${DOMAINDIR}"
exit 1
fi
# CD to the domain directory and create the domain.
startDir=\Qpwd\Q
cd ${DOMAINDIR}
CreateDomain
#Return to starting location
cd $startDir
#Use weblogic.Admin BATCHUPDATE command to configure resources
wladmin BATCHUPDATE -batchFile ConfigDomain.txt -batchCMDVerbose `
-continueOnError
You can save the commands in Listing 2-8 in a text file named ConfigDomain.txt and invoke them with the weblogic.Admin BATCHUPDATE command in Listing 2-7. Make sure that each command is on a separate, single line. For example, "CREATE_POOL myMedRecPoolXA
driver="com.pointbase.xa.xaDataSource",
url=jdbc:pointbase:server://localhost:9093/demo,
props=user=medrec;password=medrec;
DatabaseName=jdbc:pointbase:server://localhost:9093/demo,maxCapacity=10" must be on a single line.
Listing 2-8 Input for BATCHUPDATE Command
# Commands for weblogic.Admin BATCHUPDATE
############################
# Creating JDBC Resources #
############################
# Create a JDBC Connection Pool for Applications
CREATE_POOL myMedRecPoolXA
driver="com.pointbase.xa.xaDataSource",
url=jdbc:pointbase:server://localhost:9093/demo,
props=user=medrec;password=medrec;
DatabaseName=jdbc:pointbase:server://localhost:9093/demo,maxCapacity=10
# Create a Transactional Data Source
CREATE -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
# Configure the Transactional Data Source
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property JNDIName "MedRecTxDataSource"
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property PoolName "myMedRecPoolXA"
# Create another JDBC Connection Pool for the JMS JDBC Store
CREATE_POOL myMedRecPool driver="com.pointbase.jdbc.jdbcUniversalDriver",
url=jdbc:pointbase:server://localhost:9093/demo,
props=user=medrec;password=medrec,
DatabaseName=jdbc:pointbase:server://localhost:9093/demomaxCapacity=10
############################
# Creating JMS Resources #
############################
# Creating a JMS Connection Factory
CREATE -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
# Configuring the JMS Connection Factory
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property JNDIName "jms/MedRecQueueConnectionFactory"
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property XAServerEnabled "true"
#
# Creating and Configuring a JMS JDBC Store
CREATE -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
SET -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
-property ConnectionPool "mymedrec:Name=myMedRecPool,Type=JDBCConnectionPool"
SET -mbean mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore
-property PrefixName "MedRec"
# Creating and Configuring a JMS Server
CREATE -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
SET -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
-property Store "mymedrec:Name=MedRecJDBCStore,Type=JMSJDBCStore"
# Creating and Configuring a Queue
CREATE -mbean
mymedrec:JMSServer=MedRecJMSServer,Name=RegistrationQueue,Type=JMSQueue
SET -mbean
mymedrec:JMSServer=MedRecJMSServer,Name=RegistrationQueue,Type=JMSQueue
-property JNDIName "jms/REGISTRATION_MDB_QUEUE"
# Creating and Configuring an Additional Queue
CREATE -mbean mymedrec:JMSServer=MedRecJMSServer,Name=MailQueue,Type=JMSQueue
SET -mbean mymedrec:JMSServer=MedRecJMSServer,Name=MailQueue,Type=JMSQueue
-property JNDIName "jms/MAIL_MDB_QUEUE"
# Creating and Configuring an Additional Queue
CREATE -mbean mymedrec:JMSServer=MedRecJMSServer,Name=XMLQueue,Type=JMSQueue
SET -mbean mymedrec:JMSServer=MedRecJMSServer,Name=XMLQueue,Type=JMSQueue
-property JNDIName "jms/XML_UPLOAD_MDB_QUEUE"
############################
# Creating Mail Resources #
############################
CREATE -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property JNDIName "mail/MedRecMailSession"
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property Properties "mail.user=joe;mail.host=mail.mycompany.com"
#############################################
# Creating and Configuring a Managed Server #
#############################################
# Creating and Configuring a Server
CREATE -mbean mymedrec:Name=myMedRecServer1,Type=Server
SET -mbean mymedrec:Name=myMedRecServer1,Type=Server
-property ListenPort "8011"
# Targeting Resources to myMedRecServer1
SET -mbean mymedrec:Name=myMedRecPool,Type=JDBCConnectionPool
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=myMedRecPoolXA,Type=JDBCConnectionPool
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecQueueFactory,Type=JMSConnectionFactory
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedRecJMSServer,Type=JMSServer
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
SET -mbean mymedrec:Name=MedicalRecordsMailSession,Type=MailSession
-property Targets "mymedrec:Name=myMedRecServer1,Type=Server"
##############################################
# Configuring Machine and Node Manager Props #
##############################################
# Create a Machine
CREATE -mbean mymedrec:Name=WLSHost,Type=Machine
SET -mbean mymedrec:Machine=WLSHost,Name=WLSHost,Type=NodeManager
-property ListenAddress WLSHost -property ListenPort 5560
# Assign the Machine to a Server
SET -mbean mymedrec:Name=myMedRecServer1,Type=Server
-property Machine "mymedrec:Name=WLSHost,Type=Machine"
In the WebLogic Security Service, an Authentication provider is the software component that proves the identity of users or system processes. An Authentication provider also remembers, transports, and makes that identity information available to various components of a system when needed. A security realm can use different types of Authentication providers to manage different sets of users and groups. See "Authentication Providers" in Developing Security Providers for WebLogic Server.
You can use the weblogic.Admin utility to invoke operations on the following types of Authentication providers:
weblogic.management.security.authentication.AuthenticatorMBean.weblogic.management.security.authentication.LDAPAuthenticatorMBean.weblogic.security.spi.AuthenticationProvider and extend the optional The following sections describe basic tasks for managing users and groups with the weblogic.Admin utility:
For information about additional tasks that the AuthenticationProvider and the optional MBeans support, refer to the Javadoc for the weblogic.management.security.authentication package.
To invoke operations on an Authentication provider, you must specify the object name of the provider's AuthenticationProviderMBean.
The object name of the WebLogic Authentication provider is:Security:Name=realmNameDefaultAuthenticator
where realmName is the name of a security realm. For example, Security:Name=myrealmDefaultAuthenticator.
The object name of the LDAP Authentication providers is:Security:Name=realmNameLDAPAuthenticator
BEA recommends that you follow a similar convention when you create your own Authentication providers:
Security:Name=realmNameAuthenticatorName
If you use the Administration Console to add an Authentication provider to the realm, your AuthenticationProviderMBean name will follow the recommended naming convention.
To verify the object name of an AuthenticationProviderMBean, use the weblogic.Admin QUERY command. See QUERY.
To create a user, invoke the UserEditorMBean.createUser method, which is extended by the security realm's AuthenticationProvider MBean. See the Javadoc for the createUser method.
The method requires three input parameters:
username password user-description
Separate the parameters with a space. If any parameter contains a space, surround it with quotes.
The following example invokes createUser on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:8001 -username weblogic -password
weblogic invoke -mbean Security:Name=myrealmDefaultAuthenticator
-method createUser my-user1 mypassword "my user"
If the command succeeds, it prints OK to standard out.
To add a user to a group, invoke the GroupEditorMBean.addMemberToGroup method, which is extended by the security realm's AuthenticationProvider MBean. See the Javadoc for the addMemberToGroup method.
The method requires two input parameters:
The following example invokes addMemberToGroup on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:8001 -username weblogic -password
weblogic invoke -mbean Security:Name=myrealmDefaultAuthenticator
-method addMemberToGroup Administrators my-user1
If the command succeeds, it prints OK to standard out.
To verify whether a user is a member of a group, invoke the GroupEditorMBean.isMember method, which is extended by the security realm's AuthenticationProvider MBean. See the Javadoc for the isMember method.
The method requires three input parameters:
where boolean specifies whether the command searches within child groups. If you specify true, the command returns true if the member belongs to the group that you specify or to any of the groups contained within that group.
The following example invokes isMember on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:8001 -username weblogic -password
weblogic invoke -mbean Security:Name=myrealmDefaultAuthenticator
-method isMember Administrators weblogic true
If the user is a member of the group, the command prints true to standard out.
To see a list of groups that contain a user or a group, invoke the MemberGroupListerMBean.listMemberGroups method, which is extended by the security realm's AuthenticationProvider MBean. See the Javadoc for the listMemberGroups method.
The method requires one input parameter:
where memberUserOrGroupName specifies the name of an existing user or a group.
The following example invokes listMemberGroups on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:8001 -username weblogic -password
weblogic invoke -mbean Security:Name=myrealmDefaultAuthenticator
-method listMemberGroups my-user1
The method returns a cursor, which refers to a list of names. The weblogic.management.utils.NameLister.haveCurrent, getCurrentName, and advance methods iterate through the returned list and retrieve the name to which the current cursor position refers. See the Javadoc for the weblogic.management.utils.NameLister interface.
Unlimited, recursive searches for group membership can take up considerable time and produce a performance bottleneck. To control the depth of group membership searches, you can set the value of GroupMembershipSearching on the WebLogic Authentication provider, LDAP Authentication providers, or any other Authentication provider that implements the AuthenticationProvider interface.
To limit group searches, set the value of GroupMembershipSearching on the WebLogic Authentication provider or LDAP Authentication providers to limited. The GroupMembershipSearching attribute has the following valid values:
where limited specifies whether the command searches within one or more levels of a nested group hierarchy. If you specify a limited search, the MaxGroupMembershipSearchLevel attribute must be specified. The default is an unlimited search.
The MaxGroupMembershipSearchLevel attribute specifies how many levels of group membership to search. Valid values are 0 and positive integers, where 0 specifies that the command searches only within direct group memberships. A positive integer specifies the number of levels to search.
For example, when searching for membership in Group A, 0 indicates that only direct members of Group A will be found. If Group B is a member of Group A, the members of Group B will not be found by this search. If the attribute is set to 1, a search for membership in Group A will return direct members of Group A and any members of groups which are direct members of Group A. If Group B is a member of Group A, the members of Group B will also be found by this search. However, if Group C is a member of Group B, the members of Group C will not be found by this search.
See the Javadoc for GroupMembershipSearching and MaxGroupMembershipSearchLevel.
The following example gets the GroupMembershipSearching property on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:7001 -username weblogic -password weblogic get -mbean Security:Name=myrealmDefaultAuthenticator -pretty -property GroupMembershipSearching -commotype
To see a list of user or group names, you invoke a series of methods, all of which are available through the AuthenticationProvider interface:
GroupReaderMBean.listGroups and UserReaderMBean.listUsers methods take two input parameters: a pattern of user or group names to search for, and the maximum number of names that you want to retrieve.Because a security realm can contain thousands (or more) of user and group names that match the pattern, the methods return a cursor, which refers to a list of names.
See Javadoc for the listGroups method or the Javadoc for the listUsers method.
weblogic.management.utils.NameLister.haveCurrent, getCurrentName, and advance methods iterate through the returned list and retrieve the name to which the current cursor position refers. See the Javadoc for the weblogic.management.utils.NameLister interface.Because the weblogic.Admin utility does not provide the necessary control structures, you must wrap these methods in a script. See Example: Korn Shell Script for Listing Users.
weblogic.management.utils.NameLister.close method releases any server-side resources that are held on behalf of the list.The Korn shell script in Listing 2-9 retrieves up to 10 user names in a security realm.
Listing 2-9 Unix Korn Shell Script for Listing All Users
#!/bin/ksh
HOST=localhost
PORT=8001
USER=weblogic
PASS=weblogic
PROTOCOL= # can be blank, t3, t3s, http, https, etc.
if [ -z "$PROTOCOL" ]; then
URL=$HOST:$PORT
else
URL=$PROTOCOL://$HOST:$PORT
fi
Cursor=$(java weblogic.Admin -adminurl $URL -username $USER `
-password $PASS invoke `
-mbean Security:Name=myrealmDefaultAuthenticator `
-method listUsers \* 10)
haveCurrent="true"
while [[ "$haveCurrent" = "true" ]]; do
haveCurrent=$(java weblogic.Admin -adminurl $URL `
-username $USER -password $PASS invoke `
-mbean Security:Name=myrealmDefaultAuthenticator `
-method haveCurrent $Cursor)
if [[ "$haveCurrent" = "true" ]]; then
Username=$(java weblogic.Admin -adminurl $URL `
-username $USER -password $PASS invoke `
-mbean Security:Name=myrealmDefaultAuthenticator `
-method getCurrentName $Cursor)
print $Username
java weblogic.Admin -adminurl $URL -username $USER `
-password $PASS invoke `
-mbean Security:Name=myrealmDefaultAuthenticator `
-method advance $Cursor
else
print "No more names in list."
java weblogic.Admin -adminurl $URL -username $USER `
-password $PASS invoke `
-mbean Security:Name=myrealmDefaultAuthenticator `
-method close $Cursor
return
fi
done
You can save the script in Listing 2-9 in a text file and invoke it from a Korn shell. When you invoke the script, it does the following:
To change a user's password, invoke the UserPasswordEditorMBean.changeUserPassword method, which is extended by the security realm's AuthenticationProvider MBean. See the Javadoc for the changeUserPassword method.
The method requires three input parameters:
username old-password new-password
The following example invokes changeUserPassword on the WebLogic Authentication provider:
java weblogic.Admin -adminurl localhost:8001 -username weblogic -password
weblogic invoke -mbean Security:Name=myrealmDefaultAuthenticator
-method changeUserPassword my-user1 mypassword my!password
If the command succeeds, it prints OK to standard out.
Weblogic Server provides a set of attributes to protect user accounts from intruders. By default, these attributes are set for maximum protection. You can decrease the level of protection for user accounts. For example, you can increase the number of login attempts before a user account is locked, increase the time period in which invalid login attempts are made before locking the user account, or change the amount of time a user account is locked.
The AuthenticationProvider MBean does not extend methods that you use to protect user accounts. Instead, retrieve the UserLockoutManagerMBean and invoke its methods. See the Javadoc for the UserLockoutManagerMBean interface.
The following tasks provide examples for invoking UserLockoutManagerMBean methods:
The following commands set the number of consecutive invalid login attempts before a user account is locked out:
UserLockoutManagerMBean, enter the following command:java weblogic.Admin -adminurl localhost:8001 -username weblogic -password weblogic QUERY -pretty -pattern Security:*
If the command succeeds, it prints output similar to the following abbreviated example:
.
.
.
---------------------------
MBeanName: "Security:Name=myrealmUserLockoutManager"
InvalidLoginAttemptsTotalCount: 0
InvalidLoginUsersHighCount: 0
LockedUsersCurrentCount: 0
LockoutCacheSize: 5
LockoutDuration: 30
LockoutEnabled: true
LockoutGCThreshold: 400
LockoutResetDuration: 5
LockoutThreshold: 5
.
.
.
For more information about setting the value of MBean attributes, see Commands for Managing WebLogic Server MBeans.
The following command unlocks a user account:
java weblogic.Admin -adminurl localhost:8001 -username weblogic
-password weblogic invoke -mbean Security:Name=myrealmUserLockoutManager
-method clearLockout my-user1
If the command succeeds, it prints OK to standard out.
In a WebLogic Server domain, many resources are defined at the domain level and then targeted to the server instances or clusters that will use the resource. For example, a JDBC connection pool is a domain-wide resource that can be targeted to many servers or clusters. Other resources, such as Web Servers and Network Channels, are defined at the level of a server instance. These resources are not targeted because they are already child resources of a server and they cannot be shared by other server instances.
Note: Instead of targeting J2EE modules (such as enterprise applications, Web applications, and EJBs) BEA recommends that you deploy them using the weblogic.Deployer utility. See "weblogic.Deployer Utility" in Deploying WebLogic Server Applications.
To target a resource to a server or cluster:
java weblogic.Admin -adminurl adminListenAddress:ListenPort
-username username -password password
GET -type Server
where adminListenAddress:ListenPort is the listen address and listen port of the domain's Administration Server. The output includes the object name for all ServerMBean instances, as illustrated in the bold text in the following truncated output:
MBeanName: "medrec:Name=MedRecServer,Type=Server"
AcceptBacklog: 50
AdministrationPort: 0
.
.
.MBeanName: "medrec:Name=myMS1,Type=Server"
AcceptBacklog: 50
AdministrationPort: 0
.
.
.
java weblogic.Admin -adminurl adminListenAddress:ListenPort
-username username -password password
GET -type resource-MBean-type -property Targets
where adminListenAddress:ListenPort is the listen address and listen port of the domain's Administration Server and resource-MBean-type is the name of an MBean type described in Table 2-1.
For example, the following command returns a JDBCConnectionPool Administration MBean for all JDBC Connection Pools in the domain. The output includes the object name of the MyPool connection pool and indicates which servers or clusters have already been targeted to the resource:
java weblogic.Admin -adminurl localhost:8001
-username weblogic -password weblogic
GET -type JDBCConnectionPool-property Targets
In the medrec sample domain, the command returns the following, which indicates that the MedRecPool-Oracle is not targeted to a server or cluster:
MBeanName: "medrec:Name=MedRecPool-Oracle,Type=JDBCConnectionPool"
Targets:
---------------------------
MBeanName: "medrec:Name=MedRecPool-PointBase,Type=JDBCConnectionPool"
Targets: MedRecServer
java weblogic.Admin -adminurl adminListenAddress:ListenPort
-username username -password password
INVOKE -mbean resource-object-name
-method addTarget server-or-cluster-object-name This command appends an object name to the Targets attribute of a resource. It is valid only for resources whose Targets attribute can contain multiple values.
java weblogic.Admin -adminurl adminListenAddress:ListenPort
-username username -password password
SET -mbean resource-object-name
-property Targets server-or-cluster-object-name This command overwrites any existing values in the Targets attribute with the values that you specify. It is valid for any resource that includes a Targets attribute. For example:INVOKE -mbean "examples:Name=MyPool,Type=JDBCConnectionPool"
-method addTarget "examples:Name=MS1,Type=Server"
appends a server named MS2 to the list of targets for the MyPool JDBC connection pool. The following command replaces the current set of targets with a server named MS2:SET -mbean "examples:Name=MyPool,Type=JDBCConnectionPool"
-property Targets "examples:Name=MS2,Type=Server"
java weblogic.Admin -adminurl adminListenAddress:ListenPort
-username username -password password
SET -mbean server-object-name
-property resource resource-object-name Table 2-1 lists all resource types that can be targeted and provides a sample weblogic.Admin command to target the resource to the MS1 and a cluster named MedRecCluster.
|
|
||
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Individual server instances can be specified in the MBean's |
|
|
|
Individual server instances can be specified in the MBean's |
|
|
|
|
||
|
|
|
|
|
MachineMBean |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
WebLogic Server can use Simple Network Management Protocol (SNMP) to communicate with enterprise-wide management systems. The WebLogic Server subsystem that gathers WebLogic management data, converts it to SNMP communication modules (trap notifications), and forwards the trap notifications to third-party SNMP management systems is called the WebLogic SNMP agent. For more information about using SNMP with WebLogic Server, refer to the WebLogic SNMP Management Guide.
The commands in Listing 2-10 enable the WebLogic SNMP agent and configure it to send notifications (traps) to SNMP manager software.
Listing 2-10 Commands to Configure the WebLogic SNMP Agent
## Enable SNMPAgent and select a port
set -type SNMPAgent -property Enabled true -property SNMPPort 161
## create an SNMPTrapDestination where you want to send the traps that the agent
generates
create -mbean medrec:Name=myManager,SNMPAgent=medrec,Type=SNMPTrapDestination
## Select a port for the trap destination
set -mbean medrec:Name=myManager,SNMPAgent=medrec,Type=SNMPTrapDestination
-property Port 165
## Create an SNMPAttribute change trap and set the required properties
create -mbean
medrec:Name=myAttrChange,SNMPAgent=medrec,Type=SNMPAttributeChange
set -type SNMPAttributeChange -property AttributeMBeanType ServerRuntime
-property AttributeName State -property EnabledServers
medrec:Name=MedRecServer,Type=Server
## create a SNMPGaugeMonitor and set the required properties
create -mbean medrec:Name=myGauge,SNMPAgent=medrec,Type=SNMPGaugeMonitor
set -type SNMPGaugeMonitor -property MonitoredMBeanTypeExecuteQueueRuntime-property MonitoredAttributeNameExecuteThreadCurrentIdleCount
-property EnabledServers medrec:Name=MedRecServer,Type=Server
-property PollingInterval 20 -property ThresholdHigh 3 -property ThresholdLow 1
## create a SNMPStringMonitor and set the required properties
create -mbean medrec:Name=myString,SNMPAgent=medrec,Type=SNMPStringMonitor
set -type SNMPStringMonitor -property MonitoredMBeanTypeServer
-property MonitoredAttributeName StartupMode -property EnabledServers
medrec:Name=MedRecServer,Type=Server -property NotifyMatch true
-property StringToCompare RUNNING -property PollingInterval 20
## create a SNMPCounterMonitor and set the required properties
create -mbean medrec:Name=myCounter,SNMPAgent=medrec,Type=SNMPCounterMonitor
set -type SNMPCounterMonitor -property MonitoredAttributeName
ServicedRequestTotalCount -property MonitoredMBeanType ExecuteQueueRuntime
-property EnabledServers medrec:Name=MedRecServer,Type=Server -property Modulus
10 -property Offset 3 -property Threshold 3 -property PollingInterval 20
When invoked by the weblogic.Admin BATCHUPDATE command, the commands do the following (see BATCHUPDATE):
public.public.To configure the WebLogic SNMP Agent, do the following:
WL_HOME\samples\domains\medrec\startMedRecServer (Windows)WL_HOME/samples/domains/medrec/startMedRecServer.sh (UNIX)WL_HOME\server\bin\setWLSEnv.cmd (Windows)WL_HOME/server/bin/setWLSEnv.sh (UNIX)create -mbean medrec:Name=myManager,SNMPAgent=medrec,Type=SNMPTrapDestination" must be on a single line.java weblogic.Admin -url localhost:8001 -username weblogic -password weblogic BATCHUPDATE -batchFile filename -continueonerror -batchCmdVerbosewhere filename is the name of the file that you created in step 4.
Note: The above command assumes that you are running MedRecServer and the BATCHUPDATE command on the same Windows computer, and that the server is listening on port 8001. If you specified some other listen address or listen port, use the -url argument to specify your address and listen port.
The BATCHUPDATE command returns OK for each command that it successfully runs.
To verify that you successfully configured the WebLogic SNMP agent:
WL_HOME\server\bin\setWLSEnv.cmd (Windows)WL_HOME/server/bin/setWLSEnv.sh (UNIX)This command starts a daemon that listens for SNMP traps on port 165. As the WebLogic SNMP agent on the MedRecServer sends traps to the trap destination that you defined, the trap daemon prints each trap to standard out.
For more information about the snmptrapd command, refer to snmptrapd.
The weblogic.Admin BATCHUPDATE command runs a sequence of weblogic.Admin commands that you specify in a text file. This section describes how to use BATCHUPDATE to create a simple example cluster. In this example cluster, all server instances run on the same WebLogic Server host as the Administration Server.
Before you can instantiate a cluster, your WebLogic Server license must include a cluster license. If you do not have a cluster license, contact your BEA sales representative. For more information about creating clusters, refer to "Setting Up Clusters" in the Using WebLogic Server Clusters guide.
To use BATCHUPDATE to create a simple cluster in the MedRec domain, do the following:
WL_HOME\samples\domains\medrec\startMedRecServer (Windows)WL_HOME/samples/domains/medrec/startMedRecServer.sh (UNIX)WL_HOME\server\bin\setWLSEnv.cmd (Windows)WL_HOME/server/bin/setWLSEnv.sh (UNIX)calamine to refer either to the name or IP address of the computer that is running the Administration Server. java weblogic.Admin -url localhost:8001 -username weblogic -password weblogic BATCHUPDATE -batchFile filename -continueonerror -batchCmdVerbosewhere filename is the name of the file that you created in step 4.
Note: The above command assumes that you are running the MedRec server and the BATCHUPDATE command on the same Windows computer, and that the server is listening on port 8001. If you specified some other listen address or listen port, use the -url argument to specify your address and listen port.
The BATCHUPDATE command returns OK for each command that it successfully runs.
To verify that you successfully created a cluster, view the Administration Console. In the left pane of the Administration Console, open the Cluster folder and make sure that it contains a cluster named MedRecCluster. Make sure that the cluster contains two server instances named MedRecMS1 and MedRecMS2. Also verify that the servers are targeted for the machine that the command CREATE -mbean MedRec:Type=Machine,Name=calamine (from Listing 2-11) creates.
Listing 2-11 BATCHUPDATE Commands for Creating a Cluster
#Create Server Instances
CREATE -mbean medrec:Type=Server,Name=MedRecMS1
CREATE -mbean medrec:Type=Server,Name=MedRecMS2
#Configure Servers
SET -mbean medrec:Type=Server,Name=MedRecMS1 -property ListenPort 7777
SET -mbean medrec:Type=WebServer,Name=MedRecMS1,Server=MedRecMS1 -property LoggingEnabled true
SET -mbean medrec:Type=Server,Name=MedRecMS2 -property ListenPort 7778
SET -mbean medrec:Type=WebServer,Name=MedRecMS2,Server=MedRecMS2 -property LoggingEnabled true
#Create and Configure Cluster
CREATE -mbean medrec:Type=Cluster,Name=MedRecCluster
SET -mbean medrec:Type=Cluster,Name=MedRecCluster -property MulticastAddress 239.0.0.32
SET -mbean medrec:Type=Server,Name=MedRecMS1 -property Cluster medrec:Name=MedRecCluster,Type=Cluster
SET -mbean medrec:Type=Server,Name=MedRecMS2 -property Cluster medrec:Name=MedRecCluster,Type=Cluster
#Target Resources to Cluster
#The MedRec domain provides a set of JDBC Connection Pools and Data Sources
#that must be deployed to all servers in the new cluster.
SET -mbean medrec:Name=MedRecPool-PointBase,Type=JDBCConnectionPool -property Targets medrec:Name=MedRecCluster,Type=Cluster
SET -mbean medrec:Name=MedRecTxDataSource,Type=JDBCTxDataSource -property Targets medrec:Name=MedRecCluster,Type=Cluster
SET -mbean medrec:Name=jms/MedRecQueueConnectionFactory,Type=JMSConnectionFactory
-property Targets medrec:Name=MedRecCluster,Type=Cluster
#Configure Machines and Node Manager
CREATE -mbean medrec:Type=Machine,Name=calamine
CREATE -mbean medrec:Type=NodeManager,Name=calamine
SET -mbean medrec:Type=Server,Name=MedRecMS1 -property Machine medrec:Name=calamine,Type=Machine
SET -mbean medrec:Type=Server,Name=MedRecMS2 -property Machine medrec:Name=calamine,Type=Machine
#Creating the Server MBeans also creates ServerStart MBeans, which configure
#the server to be started by a Node Manager. The next commands set values for
#the ServerStart MBeans.
SET -mbean medrec:Name=MedRecMS1,Server=MedRecMS1,Type=ServerStart -property Username weblogic
SET -mbean medrec:Name=MedRecMS1,Server=MedRecMS1,Type=ServerStart -property Password weblogic
SET -mbean medrec:Name=MedRecMS2,Server=MedRecMS2,Type=ServerStart -property Username weblogic
SET -mbean medrec:Type=ServerStart,Name=MedRecMS2,Server=MedRecMS2 -property Password weblogic
After you create the cluster, you can use either the Administration Server or the weblogic.Deployer utility to deploy applications to the cluster. For more information, refer to "Deployment Tools Reference" in the Deploying WebLogic Server Applications guide and "Deploying Applications and Modules" in the Administration Console Online Help.
The commands in Listing 2-11 enable the MedRecMS1 and MedRecMS2 server instances to be started by the Node Manager. For information on setting up Managed Servers to be started by a Node Manager, refer to the following sections in the Configuring and Managing WebLogic Server guide:
|
|
|