Start and Stop the Gateway

This topic describes the correct ways to stop and restart a gateway. You need to stop the Gateway to perform certain maintenance tasks.
gateway93
This topic describes the correct ways to stop and restart a
Layer7 API Gateway
. You need to stop the Gateway to perform certain maintenance tasks.
Contents:
(1) Rebooting the Gateway appliance is a common task after installing, upgrading, importing, patching, and so on. To avoid data loss, never power cycle the physical or virtual machine. For example, do not use the power button or the power control functionality in the ILOM for a physical machine, or by using the Reset command in the vSphere Client. (2) Support recommends removing Gateway nodes from the load balancer pool before stopping or restarting the Gateway.
Appliance Gateway
You can stop and start the Appliance Gateway with a single command:
service ssg restart
Stopping the Gateway
There are two ways to stop a Gateway node.
When installing a patch, always start and stop the Gateway using the menu method. Using the command line method also stops an internal process that is vital for the patching process.
To stop the Appliance Gateway using the menu:
  1. Access the Gateway main menu.
  2. Choose option
    2
    (Display
    Layer7 API Gateway
    configuration menu).
  3. Choose option
    7
    (Manage
    Layer7 API Gateway
    status). The current status of the Gateway is displayed. Press [
    Enter
    ] to continue.
  4. Select the option to stop the Gateway. It may take a moment for the Gateway to stop completely. Use option
    7
    to monitor the stoppage ("STOPPING" indicates the node is still stopping; "STOPPED" indicates the node has stopped).
To stop the Appliance Gateway using the command line:
  1. Run the command:
    # service ssg stop
Starting the Gateway
To start the
Appliance
Gateway using the menu:
  1. Access the Gateway main menu.
  2. Choose option
    2
    (Display
    Layer7 API Gateway
    configuration menu).
  3. Choose option
    7
    (Manage
    Layer7 API Gateway
    status). The current status of the Gateway is displayed. Press [
    Enter
    ] to continue.
  4. Select the option to start the Gateway. It may take a moment for the Gateway to fully start. Use option
    7
    to monitor the startup ("STARTING" indicates the node is still starting; "RUNNING" indicates the node is up and running normally).
To start the
Appliance
Gateway using the command line:
  1. Run the command:
    # service ssg start
Configuring Autostart on Reboot
The Gateway normally starts automatically after the appliance is rebooted.
To disable autostart on reboot:
  1. Access the Gateway main menu.
  2. Choose option
    2
    (Display
    Layer7 API Gateway
    configuration menu).
  3. Choose option
    3
    (Configure the
    Layer7 API Gateway
    ).
  4. Choose option
    4
    (Change node configuration).
  5. Enter
    no
    to disable the node. The Gateway does not start automatically upon reboot.
To enable autostart on reboot:
  • Repeat the steps above, entering
    yes
    in step 5. The Gateway automatically starts upon reboot.
Troubleshoot Gateway Start
If you are attempting to debug Gateway start issues, use the “run” mode to log each step of the startup sequence. This log helps Support troubleshoot your issue.
Use the following “run” option only while troubleshooting; it is not intended for production use.
To start the
Appliance
Gateway in debug mode:
  1. Enter the command:
    # ./runtime/bin/gateway.sh run
    You see messages similar to this:
    [[email protected] Gateway]$ ./runtime/bin/gateway.sh run Nov 3, 2015 3:42:24 PM com.l7tech.server.ServerConfig <init>
    INFO: Couldn't find serverconfig_override.properties; continuing with no overrides Nov 3, 2015 3:42:26 PM com.l7tech.server.boot.GatewayBoot start
    These messages are output to the console as well as recorded in the log file.
  2. To stop the Gateway and exit the debug mode, press [
    Ctrl
    ]-
    C
    .
Software Gateway
The
gateway.sh
script can only be run by
gateway
or
root
users.
Starting the Software Gateway
To start the Software Gateway:
  1. Log in as the
    gateway
    or
    root
    user.
  2. Run the following command:
    # /opt/SecureSpan/Gateway/runtime/bin/gateway.sh start
You can monitor the Gateway startup process by using the "tail" command to echo the log information to the screen:
tail -f /opt/SecureSpan/Gateway/node/default/var/logs/ssg_0_0.log
What to watch for: Messages containing "Warning" or a "stack trace" indicate a problem with the Gateway and require immediate attention. When you see "INFO: Server Ready", the Gateway has started successfully.
Troubleshooting Gateway Start
If you are attempting to debug Gateway start issues, you can use the "run" mode to log each step of the startup sequence. This log helps CA Technical Support troubleshoot your issue.
Use the "run" mode only for troubleshooting; it is not intended for production use.
To start the Gateway in debug mode:
  1. Log in as the
    gateway
    or
    root
    user.
  2. Enter the command:
    # ./runtime/bin/gateway.sh run
    You see messages similar to:
    [[email protected] Gateway]$ ./runtime/bin/gateway.sh run Nov 3, 2013 3:42:24 PM com.l7tech.server.ServerConfig <init>
    INFO: Couldn't find serverconfig_override.properties; continuing with no overrides Nov 3, 2013 3:42:26 PM com.l7tech.server.boot.GatewayBoot start
    These messages are output to the console as well as recorded in the log file.
  3. To stop the Gateway, press [
    Ctrl
    ]-
    C
    .
Stopping the Software Gateway
To stop the Software Gateway:
  1. Log in as the
    gateway
    or
    root
    user.
  2. Run the following command:
    # /opt/SecureSpan/Gateway/runtime/bin/gateway.sh stop