Skip to content

Instantly share code, notes, and snippets.

@kymtwyf
Last active June 4, 2016 03:28
Show Gist options
  • Save kymtwyf/53e8b60a874d0f272925 to your computer and use it in GitHub Desktop.
Save kymtwyf/53e8b60a874d0f272925 to your computer and use it in GitHub Desktop.
ubuntu server install jdk tomcat

Reference

download jdk and install here

  1. download jdk using wget

    wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/7u79-b15/jdk-7u79-linux-x64.tar.gz

  2. extract to folder tar -vxzf jdkXXX.tar.gz -C /opt
  3. set JAVA_HOME, JRE_HOME, CLASS_PATH, PATH
export JAVA_HOME="/opt/jdk1.8.0_65"
export JAVA="/opt/jdk1.8.0_65"
export JRE_HOME="/opt/jdk1.8.0_65/jre"
export CLASS_PATH=.:$JAVA_HOME/lib:$JRE_HOME/libe
export PATH=$JAVA_HOME/bin:$PATH

download and start tomcat

  1. [download tomcat using wget]

    wget http://apache.opencas.org/tomcat/tomcat-9/v9.0.0.M1/bin/apache-tomcat-9.0.0.M1.tar.gz

  2. extract to folder tar -vxzf apachexxx.tar.gz -C /opt
  3. modify conf/tomcat-users.xml add add user for role manager-gui
  4. start tomcat bin/startup.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment