centos7中使用yum安装tomcat mysql 等
本站寻求有缘人接手,详细了解请联系站长QQ1493399855
安装Tomcat
进入
# cd /usr/local/tomcat
# wget http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-7/v7.0.94/bin/apache-tomcat-7.0.94-fulldocs.tar.gz
官网下载地址:http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-7/v7.0.94/bin/apache-tomcat-7.0.94-fulldocs.tar.gz
(如果下载有问题,请到官网:http://tomcat.apache.org/ 下载)
解压文件:tar -zxvf apache-tomcat-7.0.94-fulldocs.tar.gz
移动到根目录下:mv apache-tomcat-7.0.82 /
运行 tomcat :./startup.sh
关闭 tomcat: ./shutdowm.sh
登录
cd /usr/local/tomcat/bin 进入bin
./shutdown.sh 关闭
ps -ef|grep java 查看Tomcat是否以关闭
./startup.sh 启动Tomcat
防火墙
启动防火墙:systemctl start firewalld.service
查开方端口:firewall-cmd --zone=public --list-ports
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running)