1、购买阿里云Linux ecs系统镜像centos并配置实例
安全组:maven分布式项目部署阿里云Linux centos_7_03_64
maven分布式项目部署阿里云Linux centos_7_03_64
2、安装jdk和tomcat
tomcat
安装2个,修改端口,一个为8080和8081.
service.xml下,tomcat1为:

<Server port="8005" shutdown="SHUTDOWN">
<Connector port="8080" protocol="HTTP/1.1"
connectionTimeout="20000"  redirectPort="8443" />
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />

则tomcat2为

<Server port="8015" shutdown="SHUTDOWN">
 <Connector port="8081" protocol="HTTP/1.1" 
 connectionTimeout="20000" redirectPort="8443" />
 <Connector port="8019" protocol="AJP/1.3" redirectPort="8443" />

3、可参考我的博文,安装zookeeper
4、安装mysql,参考此篇博文即可
navicat连接远程阿里云mysql出现的问题和解决办法:mysql开启外网访问权限

遇到的问题:
注意:maven分布式项目部署阿里云Linux centos_7_03_64
话外:密码重置参考:参考链接

接着把本地数据库备份:
maven分布式项目部署阿里云Linux centos_7_03_64

本地navicat连接上远程阿里云mysql后的导入备份:……此略
注:新建的数据库名要和db.perperties保持一致:
maven分布式项目部署阿里云Linux centos_7_03_64

5、eclipse导出项目maven分布式项目war包,导出service和web即可
maven分布式项目部署阿里云Linux centos_7_03_64
maven分布式项目部署阿里云Linux centos_7_03_64
注:图中为service的分布式maven war包导出,web同理。
maven分布式项目部署阿里云Linux centos_7_03_64

6、将service的war包放在tomcat1(8080端口)的webapps下,更名ROOT.war。
web的war包同做。
期间重启tomcat1和tomcat2。

在webapps下点击进入root文件夹下看到自己的文件,即表示成功。
maven分布式项目部署阿里云Linux centos_7_03_64
maven分布式项目部署阿里云Linux centos_7_03_64
web导入成功同理。
7、部署成功:
maven分布式项目部署阿里云Linux centos_7_03_64
访问链接

相关文章:

  • 2021-12-08
  • 2021-09-29
  • 2021-06-18
  • 2021-05-21
  • 2021-05-31
  • 2021-12-18
  • 2021-07-14
猜你喜欢
  • 2021-09-14
  • 2022-12-23
  • 2022-12-23
  • 2021-12-22
  • 2022-01-01
相关资源
相似解决方案