Restart Web Server

Occasionally, it may be necessary to restart the web server in the NexOSS. For example, increasing the amount of RAM allocated to Java for requires that the web server be restarted. The following instructions explain how to stop and restart the web server.

  1. To see if the web server is running. Use a combination of “ps” and “grep” utilities.
   $ ps -ef | grep WebServer | grep -v grep

Sample output, when the web server is running and its process id is 28658

   ossadmin 28658 1 0 Apr02 ? 00:11:14 /home/ossadmin/OSS/nexoss/jdk/bin/java -DNexOSSWebServer -server -mx6000M -Djava.endorsed.dirs=/home/ossadmin/OSS/nexoss/nexoss/WebServer/common/endorsed -classpath /home/ossadmin/OSS/nexoss/jdk/lib/tools.jar:/home/ossadmin/OSS/nexoss/WebServer/bin/bootstrap.jar -Dcatalina.base=/home/ossadmin/OSS/nexoss/WebServer -Dcatalina.home=/home/ossadmin/OSS/nexoss/WebServer -Djava.io.tmpdir=/home/ossadmin/OSS/nexoss/WebServer/temp org.apache.catalina.startup.Bootstrap start

When the web server is not running, there is no output.

  1. To stop the web server
   cd $NexOSS_HOME/unix/run
   ./stop_web_server.sh

If the web server is running. The stop script will continue to log dots until the web server actually stops. Example

   Using CATALINA_BASE: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_HOME: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_TMPDIR: /home/ossadmin/OSS/nexoss/WebServer/temp
   Using JAVA_HOME: /home/ossadmin/OSS/nexoss/jdk
   ....

If the web server is NOT running. The stop script will log “connection refused”. Example

   Using CATALINA_BASE: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_HOME: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_TMPDIR: /home/ossadmin/OSS/nexoss/WebServer/temp
   Using JAVA_HOME: /home/ossadmin/OSS/nexoss/jdk
   Catalina.stop: java.net.ConnectException: Connection refused
   java.net.ConnectException: Connection refused
  1. To start the web server.
   cd $NexOSS_HOME/unix/run
   ./run_web_server.sh
   Using CATALINA_BASE: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_HOME: /home/ossadmin/OSS/nexoss/WebServer
   Using CATALINA_TMPDIR: /home/ossadmin/OSS/nexoss/WebServer/temp
   Using JAVA_HOME: /home/ossadmin/OSS/nexoss/jdk