Start and Stop a Domain

Oracle WebLogic Server for Oracle Cloud Infrastructure provides utilities to manage the server processes in your domain.

With these utilities you can stop, start, or restart (stop and then start) the WebLogic Server and Node Manager processes in your domain.

  1. Identify the IP address of the node in your domain.

    The name of the node is servicename-wls-n, where servicename is the resource name prefix you provided during stack creation. The Administration Server runs on the first node, servicename-wls-0

    • If your domain is on a public subnet, then use the public IP address of the compute instance.
    • If your domain is on a private subnet, then use the public IP address of the bastion and the private IP address of the compute instance.
  2. Open an SSH connection to the node as the opc user.
    ssh -i <path_to_private_key> opc@<node_public_ip>

    Or,

    ssh -i <path_to_private_key> -o ProxyCommand="ssh -W %h:%p -i <path_to_private_key> opc@<bastion_public_ip>" opc@<node_private_ip>
  3. Change to the oracle user.
    sudo su - oracle
  4. Execute the restart_domain.sh script.
    /opt/scripts/restart_domain.sh -o [start|stop|stopMS|restart]
    • start - start the Node Manager and all servers on this node
    • stop - stop the Node Manager and all servers on this node
    • stopMS - stop only the Managed Server process on this node
    • restart - stop and then start the Node Manager and all servers on this node

    To execute the stop operation, the Administration Server and Node Manager must be running.

    If you modified certain settings after creating the domain, like the administrator password or port number, then you must provide additional parameters to restart_domain.sh:

    • -u - User name for the domain administrator
    • -p - Password for the domain administrator
    • --adminhost - Hostname of the administration server
    • --port - Port number of the administration server
    • --domain-name - Name of the domain
    • --domain-home - Home directory for the domain
    • --admin-servername - Name of the administration server

    If your domain is running Oracle WebLogic Server 11g and you configured the servers to use a custom trust keystore, then set the location of the file in the JAVA_OPTIONS environment variable before running restart_domain.sh. For example:

    export JAVA_OPTIONS="${JAVA_OPTIONS} -Dweblogic.security.SSL.trustedCAKeyStore=/u01/data/mytrust.jks"