Java项目上线之服务器环境配置篇(二)——Tomcat配置
Tomcat的选择:
配置步骤:
cd /usr/local
mkdir tomcat
scp 本地文件绝对路径 root@8.888.88.888服务器IP地址:需要传入到服务的哪个文件下的绝对路径
tar -zxvf apache-tomcat-9.0.55.tar.gz
cd /usr/local/tomcat/apache-tomcat-9.0.55/bin
./startup.sh
./shutdown.sh
systemctl status firewalld
yum install firewalld firewall-config
service firewalld start
启动防火墙:systemctl start firewalld
禁用防火墙:systemctl stop firewalld
重启防火墙:firewall-cmd --reload
查看防火墙状态:systemctl status firewalld
firewall-cmd --zone=public --permanent --add-port=8080/tcp
firewall-cmd --zone=public --permanent --add-port=8083/tcp
firewall-cmd --zone=public --permanent --add-port=3306/tcp
firewall-cmd --reload
firewall-cmd --list-all
./shutdown.sh
./startup.sh