Intro to Tomcat's management in Linux

  1. In Linux, Tomcat can be typically installed at a few possible location such as

    Note : At KWT server, Tomcat is installed at /var/lib/tomcat8/

    2. Tomcat has a few Environment Variables

    $CATALINA_HOME : where Tomcat is installed
    $CATALINA_PID : location of pid file for Tomcat running process (will discuss later)

    3. To start Tomcat, usually we can run : “$CATALINA_HOME/bin/ start”

    4. Once Tomcat is running, the pid of the Tomcat process is writen into a file which is declared in $CATALINA_PID.
    Typically value for $CATALINA_PID is $CATALINA_BASE\bin\

    When you open this file, (run “less $CATALINA_BASE\bin\”), you will see the pid of the Tomcat process

    5. You stop Tomcat process by running : “kill -kill 1239” (replace 1239 with the pid of the process)
    This is a generic Linux’s way of killing any process.

    6. Typically, to stop Tomcat, you run “$CATALINA_HOME/bin/ start”

    NOTE : To add more : Logging, folder structure, manager, host manager, multiple instance, users, server setting</div>