![]() |
![]() |
|
|
Starting and Shutting Down a Server
WebLogic Portal provides startup scripts for each of its reference domains. We recommend that you create scripts similar to these to activate and shut down servers in your own domain.
This topic includes the following sections:
This topic describes starting and stopping portalDomain because this domain provides the most detailed example of WebLogic Portal features. For information on starting the other reference domains, refer to Review the Reference Domains.
Starting portalDomain on UNIX
From a WebLogic Portal host, enter the following command where PORTAL_HOME is the directory into which you installed WebLogic Portal:
PORTAL_HOME/StartPortal.sh
The StartPortal.sh calls PORTAL_HOME/config/portalDomain/startPortal.sh, which calls set-environment.sh to set environment variables. Then it passes to the JVM the class name and parameters that start WebLogic Server, WebLogic Portal, and activate the portalDomain and its servers.
For information on starting a server without using StartPortal.sh (for example, if you want to create a script for your own environment), refer to the following sections:
Starting portalDomain on Windows
From a Windows WebLogic Portal host, do one of the following:
The Start WebLogic Portal Server command on the Start menu is a shortcut to StartPortal.bat. The StartPortal.bat calls PORTAL_HOME/config/portalDomain/startPortal.bat, which calls set-environment.bat to set environment variables. Then it passes to the JVM the class name and parameters that start WebLogic Server, WebLogic Portal, and activate portalDomain and its servers.
For information on starting a server without using StartPortal.bat or the Start WebLogic Portal Server command (for example, if you want to create a script for your own environment), refer to the following sections:
Startup Confirmation
When you issue a startup command, WebLogic Portal displays messages in the shell that contains the server process. The following three messages indicate that the server started successfully:
< DATE > <Notice> <WebLogicServer> <ListenThread listening on port NUMBER>
< DATE > <Notice> <WebLogicServer> <SSLListenThread listening on port NUMBER>
< DATE > <Notice> <WebLogicServer> <Started WebLogic Admin Server "server-name" for domain "domain-name">
For information about changing the number and type of messages that WebLogic Portal displays in the shell and saves to log files, refer to Configure the Message Output.
Setting Environment Variables
Before starting the server, you must set environment variables and add directories to the system path. Although the set-environment file does this for you, you can set the variables in any other way that your operating system supports.
This section describes the following tasks:
Create New Environment Variables
Create the following new environment variables:
Note: The examples in the following list are from a Windows set-environment.bat file.
Add Directories to CLASSPATH
Add the following directories to the CLASSPATH variable:
Note: For ease of maintenance, the set-environment file groups these directories into several variables. Then it adds the variables to the CLASSPATH.
Add Directories to the System PATH
Add the following directories to the system PATH variable:
Java Command for Starting a Server
WebLogic Server is a Java class file, and like any Java application, you can start it with the java command. The arguments needed to start WebLogic Server with WebLogic Portal classes from the command line can be quite lengthy and typing it out whenever you need to start the server can be tedious.
You must include the following arguments to start an instance of a WebLogic Administration Server that includes WebLogic Server with WebLogic Portal classes:
For Windows:
or
Invokes the HotSpot Client VM. For more information, see "Use the HotSpot Virtual Machine" in the Performance Tuning Guide.
Note: For the default Cloudscape database, Windows uses -classic as a default.
For Linux or Solaris:
or
or
Invokes the HotSpot Client VM or Server VM.
For HP-UX or AIX:
or
Invokes the HotSpot Client VM.
Note: WebLogic Portal does not specify this setting, so it defaults to the Client VM.
Specifies the initial and maximum values for Java heap memory. The values assigned to these parameters can dramatically affect the performance of WebLogic Server and are provided here only as general defaults. In a production environment you should carefully consider the correct memory heap size to use for your applications and environment.
Sets the java -classpath option. The minimum content for this option is described in Add Directories to CLASSPATH.
Where DOMAIN_NAME is the name of the domain that contains your Web applications. The domain name must match the name of a directory whose parent directory is named config. In addition, the domain directory must contain a config.xml file that conforms to the WebLogic domain-configuration DTD.
For example, if your domain is located in /usr/config/myPortalDomain, then use the following argument:
-Dweblogic.Domain=myPortalDomain
Where SERVER_NAME is a logical name of the server instance. When a WebLogic Managed Server requests its configuration information from the Administration Server, it identifies itself to the Administration Server by server name.
Where host is the name or IP address of the machine where the Administration Server is running and port is the Administration Server's listen port. By default the listen port for WebLogic Portal Administration Servers is 7501. For more information about starting Managed Servers, refer to "Starting a WebLogic Managed Server" under "Starting and Stopping WebLogic Servers" in the WebLogic Server Administration Guide.
Where BEA_HOME is the directory that contains BEA license files.
Where WEBLOGIC_HOME is the directory into which you installed WebLogic Server. This argument specifies the Java security policy for the server.
Where PORTAL_HOME is the directory into which you installed WebLogic Portal. These arguments load WebLogic Portal classes.
For example, the StartPortal script for an Administration Server on Windows issues the following command:
%JDK_HOME%\bin\java -hotspot -Xms128m -Xmx128m -classpath %CLASSPATH% -Dcloudscape.system.home=PORTAL_HOME/db/data -Dweblogic.Domain=%DOMAIN_NAME%
-Dweblogic.Name=%SERVER_NAME% -Dbea.home=%BEA_HOME% -Djava.security.policy==%WEBLOGIC_HOME%/lib/weblogic.policy -Dcommerce.properties=PORTAL_HOME/weblogiccommerce.properties
weblogic.Server
Shutting Down a Server
To shut down the portalServer and portalDomain, use the StopPortal script, which is located in the WebLogic Portal installation directory.
To use the StopPortal script on UNIX, open a shell and enter the following command:
PORTAL_HOME/StopPortal.sh
To use the StopPortal script on Windows, enter the following command from a DOS prompt or equivalent command prompt:
PORTAL_HOME/StopPortal.bat
where PORTAL_HOME is the directory in which you installed WebLogic Portal.
Although it is possible to shut down the server by closing the shell that contains the process or by typing CTRL+C in the shell, such an abrupt action can cause transactions to be rolled back and any uncommitted session data to be lost. In addition, you can use the WebLogic Server Administration Console to shut down a WebLogic Portal instance.
![]() |
![]() |
![]() |
|
Copyright © 2001 BEA Systems, Inc. All rights reserved.
|