Tomcat9.0部署iot.war(环境mysql8.0,centos7.2)

下载安装包

安装mysql8.0

#####安装软件包#####
# tar -xf mysql-8.0.11-1.el7.x86_64.rpm-bundle.tar -C /opt/mysql
# createrepo /opt/mysql
# yum-config-manager --add-repo=file:///opt/mysql
# echo "gpgcheck=0" >> /etc/yum.repos.d/_opt_mysql.repo
# yum -y install mysql-community-server
# systemctl start mysqld
# ^start^enable
# netstat -lnput | grep 3306

#####重置MySQL密码#####
# grep 'temporary password' /var/log/mysqld.log
2018-06-12T07:37:39.045310Z 5 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: 'elsq#kB%5Xgx'
# mysql -uroot -pelsq#kB%5Xgx
mysql> alter user 'root'@'localhost'identified with mysql_native_password by "Mr.Testder"

安装jdk

# tar -xzf jdk-8u77-linux-x64.tar.gz -C /usr/
# vim /etc/profile
export JAVA_HOME=/usr/jdk1.8.0_77
export PATH=$JAVA_HOME/bin:$PATH
# source /etc/profile
# java -version
java version "1.8.0_77"
Java(TM) SE Runtime Environment (build 1.8.0_77-b03)
Java HotSpot(TM) 64-Bit Server VM (build 25.77-b03, mixed mode)

安装tomcat9.0

# tar -xzf apache-tomcat-9.0.8.tar.gz
# mv apache-tomcat-9.0.8 /usr/local/tomcat

tomcat部署war包

# rm -rf /usr/local/tomcat/webapps/*
# mv iot.war /usr/local/tomcat/webapps
# cd /usr/local/tomcat/bin
# ./startup.sh
# netstat -lnptu | grep 8080
# ps -ef | grep [j]ava
# tailf logs/catalina.out
26-Jan-2016 06:10:24.195 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
26-Jan-2016 06:10:24.206 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"]
26-Jan-2016 06:10:24.211 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 1560 ms
上一篇:python之钉钉机器人zabbix报警


下一篇:善用资料搜集与分析 智能城市可增进居民健康