系统:Ubuntu,Tomcat:apache-tomcat-8.5.23.tar.gz
1,找到apache-tomcat-8.5.23.tar.gz,复制到 /usr/local
root@ubuntu:/mnt/hgfs/share# cp apache-tomcat-8.5.23.tar.gz /usr/local
2,解压
root@ubuntu:/mnt/hgfs/share# cd /usr/local
root@ubuntu:/usr/local# tar -xzvf apache-tomcat-8.5.23.tar.gz
解压后得到apache-tomcat-8.5.23文件夹
3,进入bin目录,启动Tomcat
root@ubuntu:/usr/local# cd apache-tomcat-8.5.23/
root@ubuntu:/usr/local/apache-tomcat-8.5.23# cd bin/
root@ubuntu:/usr/local/apache-tomcat-8.5.23/bin# ./startup.sh
看到下面的说明启动成功了
Using CATALINA_BASE: /usr/local/apache-tomcat-8.5.23
Using CATALINA_HOME: /usr/local/apache-tomcat-8.5.23
Using CATALINA_TMPDIR: /usr/local/apache-tomcat-8.5.23/temp
Using JRE_HOME: /usr/java/jdk-9.0.1
Using CLASSPATH: /usr/local/apache-tomcat-8.5.23/bin/bootstrap.jar:/usr/local/apache-tomcat-8.5.23/bin/tomcat-juli.jar
Tomcat started.
4,打开浏览器,输入http://localhost:8080/
访问成功了
5,停止服务器
root@ubuntu:/usr/local/apache-tomcat-8.5.23/bin# ./shutdown.sh