如何在linux 下载Tomcat
时间: 2024-05-22 17:12:45 浏览: 63
1. 打开终端
2. 输入以下命令安装Tomcat:
sudo apt-get update
sudo apt-get install tomcat8
3. 等待安装完成后,输入以下命令启动Tomcat:
sudo systemctl start tomcat8
4. 验证Tomcat是否已经启动成功,输入以下命令:
sudo systemctl status tomcat8
如果Tomcat已经启动,会返回如下信息:
● tomcat8.service - LSB: Apache Tomcat 8 Servlet/JSP Container
Loaded: loaded (/etc/init.d/tomcat8; generated)
Active: active (running) since Wed 2021-11-10 10:52:25 CST; 5s ago
Docs: man:systemd-sysv-generator(8)
Tasks: 39 (limit: 4915)
CGroup: /system.slice/tomcat8.service
└─1755 /usr/lib/jvm/java-8-openjdk-amd64/bin/java -Djava.util.logging.config.file=/var/lib/tomcat8/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLo...
5. 打开浏览器,在地址栏输入http://localhost:8080/,如果看到Tomcat的欢迎页面,说明Tomcat已经安装并运行成功。
阅读全文