NonStop Server Guide for BEA WebLogic Server 8.1

Configuring Persistent WebLogic Server Processes
HP NonStop Server Guide for BEA WebLogic Server 8.1529891-001
4-8
Starting a Managed Server Through the Node
Manager
Starting a Managed Server Through the Node Manager
When NativeVersionEnabled is set to false as required on the NonStop server, the
Node Manager uses a shell script to start a Managed Server. By default that script is
named nodemanager.sh, but can be changed using the StartTemplate property.
The Node Manager passes four arguments to the script:
Java command-line
stdout to use
stderr to use
Filename where the pid of the Java process should be written
Therefore, the nodemanager.sh could be as simple as:
#!/bin/sh
. $WL_HOME/common/bin/commEnv.sh
java $1 > $2 2>$3 &
echo $! > $4
To take advantage of the NonStop server multi-CPU architecture, a sample script and
executable are provided that will balance the Managed Servers throughout the system.
The nodemanager.sh script is stored in $WL_HOME/server/lib/unix. The script
performs some simple processing and then runs a C program, CPUselector, in the
same directory to select what CPU should be used by the Managed Server. The script
then starts the Managed Server.
nodemanager.sh
The nodemanager.sh script reads in a server environment file to allow environment
variables to be set per server. It invokes the C program named CPUselector to
perform the load-balancing functionality. Once CPUselector completes, the script
starts the Managed Server in the appropriate CPU.
The WebLogic Server uses replication groups to support fault-tolerance by allowing a
primary and secondary server to retain state information. To avoid a single point of
failure requires the primary and secondary server not be started in the same CPU on a
NonStop server. nodemanager.sh and CPUselector allow you to ensure the
primary and secondary server will not be started on the same CPU.
To support replication groups, CPUs are specified for use using a new environment
variable named WLS_CPUS. Furthermore, the order the CPUs are listed in WLS_CPUS
determines the order the CPUs are scanned when comparing the load of each CPU.
nodemanager.sh scans the script's arguments to determine the server's name to set
the environment variable WLS_SERVER. It then looks for the server environment file in
the current working directory. By default, the server environment file is named nm-
server.env and must be located in $WL_HOME/common/nodemanager, but both
values can be changed in the nodemanager.sh script. If the file is present, the script
invokes the file (for example, . nm-server.env). The script can then use the variable