0 Votes

Startup

Last modified by Jeff McDonald on 2021/11/26 15:18

Test Configuration

To start the WebLogic AdminServer:

cd <domain>/bin
./startWebLogic.sh

If the server will not start cleanly, check the "config/config.xml" file.

Look at the defined "listen-address" for the AdminServer.

Start the managed nodes like so...

./startManagedWebLogic.sh engine1
./startManagedWebLogic.sh engine2

Look at the terminal output. Save the CLASSPATH and startup line.

Example CLASSPATH:

/usr/java/jdk1.8.0_271-amd64/lib/tools.jar:/opt/oracle/occas71/wlserver/server/lib/weblogic.jar:/opt/oracle/occas71/wlserver/../oracle_common/modules/thirdparty/ant-contrib-1.0b3.jar:/opt/oracle/occas71/wlserver/modules/features/oracle.wls.common.nodemanager.jar:/opt/oracle/occas71/wlserver/sip/server/lib/weblogic_sip.jar:/opt/oracle/occas71/occas/server/lib/platform/oracle.sdp.occas.depended.jar:/opt/oracle/occas71/wlserver/common/derby/lib/derbyclient.jar:/opt/oracle/occas71/wlserver/common/derby/lib/derby.jar

Example Startup:

/usr/java/jdk1.8.0_271-amd64/bin/java -server   -Xms256m -Xmx512m  -cp /opt/oracle/occas71/wlserver/server/lib/weblogic-launcher.jar -Dlaunch.use.env.classpath=true -Dweblogic.Name=engine1 -Djava.security.policy=/opt/oracle/occas71/wlserver/server/lib/weblogic.policy  -Dweblogic.ProductionModeEnabled=true  -Dwlss.maddr.enable=true -Dweblogic.security.SSL.minimumProtocolVersion=TLSv1 -Djava.system.class.loader=com.oracle.classloader.weblogic.LaunchClassLoader -Dwlss.replication=on -Dwlss.callstate.manager.classname=com.bea.wcp.sip.replicatedstore.server.CoherenceCallStateManager  -javaagent:/opt/oracle/occas71/wlserver/server/lib/debugpatch-agent.jar -da -Dwls.home=/opt/oracle/occas71/wlserver/server -Dweblogic.home=/opt/oracle/occas71/wlserver/server   -Dweblogic.management.server=http://usbank:7001   weblogic.Server

We will use these values when configuring Node Manager.

Production Mode

To start WebLogic in 'production' mode, create a file called 'boot.properties'.

Place this file in the 'security' folder of the AdminServer...

<domain>/servers/AdminServer/security/boot.properties

Set the contents like this...

username=weblogic
password=weblogic123

Node Manager

Kill engine1 & engine2. (Ctrl+C)

Modify the nodemanager.properties file (found in <domain>/nodemanager).

ListenAddress=0.0.0.0
SecureListener=false
weblogic.StartScriptEnabled=false

Start the Node Manager manually...

./startNodeManager.sh

Login to the console...

http://<host>:7001/console

Create machines for each physical server in the cluster:

  • Change type from SSL to plain
  • Change the listen address from localhost to the hostname of the server
  • Add the desired server to each machine
  • Add the classpath to the server's "Server Start" page (required)
  • Add optional startup arguments (revisit during performance tuning)

Note: It is unnecessary to create a machine for the AdminServer.

Start the servers from the admin console to test.

Verify the startup parameters are how you like them...

ps -eaf | grep java

Startup Scripts

NodeManager

Create new file /etc/systemd/system/nodemanager.service:

## create new file /etc/systemd/system/nodemanager.service for nodemanager, then systemctl daemon-reload
[Unit]
Description=Controls Node Manager Lifecycle
After=network.target sshd.service

[Service]
User=oracle
Group=oinstall
Type=simple
WorkingDirectory=/opt/oracle/occas71/user_projects/domains/usbank
ExecStart=/opt/oracle/occas71/user_projects/domains/usbank/bin/startNodeManager.sh
ExecStop=/opt/oracle/occas71/user_projects/domains/usbank/bin/stopNodeManager.sh
Restart=on-failure
RestartSec=1
KillMode=process
LimitNOFILE=65535

[Install]
WantedBy=default.target

AdminServer

Create new file /etc/systemd/system/weblogic.service

## create new file /etc/systemd/system/weblogic.service for weblogic admin server, then systemctl daemon-reload
[Unit]
Description=Controls WebLogic Admin Server Lifecycle
After=network.target sshd.service

[Service]
User=oracle
Group=oinstall
Type=simple
WorkingDirectory=/opt/oracle/occas71/user_projects/domains/usbank
ExecStart=/opt/oracle/occas71/user_projects/domains/usbank/bin/startWebLogic.sh
ExecStop=/opt/oracle/occas71/user_projects/domains/usbank/bin/stopWebLogic.sh
Restart=on-failure
RestartSec=1
KillMode=process
LimitNOFILE=65535

[Install]
WantedBy=default.target

Now enable / start them

systemctl daemon-reload
systemctl enable nodemanager
systemctl start nodemanager
systemctl enable weblogic
systemctl start weblogic

Verify the AdminServer is running.

Verify you can start the managed servers.