1. ./update  
  2. +--------------------------------------------------------------+ 
  3. | === 确定特定用户执行,否则退出  === | 
  4. +--------------------------------------------------------------+ 
  5. Yes,we are the user of testtomcat  
  6.  
  7.  
  8. +--------------------------------------------------------------+ 
  9. | === 确认是否需要升级,升级项目数目,否则退出  === | 
  10. +--------------------------------------------------------------+ 
  11. When you run this script,it will upgrade the project ops networkresourcemanage  
  12. Would you like do that?(yes/no)yes 
  13.     Let's go,update the project.  
  14.  
  15.  
  16. +--------------------------------------------------------------+ 
  17. | === 由于升级需要,准备杀掉tomcat进程,请慎重!!!!!  === | 
  18. +--------------------------------------------------------------+ 
  19. ###################################### 
  20. ##WARNING.I WANT TO KILL THE TOMCAT.## 
  21. ###################################### 
  22. Would you like do that?(yes/no)yes 
  23. Let's go,update the project.  
  24. kill the tomcat service instance,please hold on 5 seconds......... 
  25. progress:[##################################################]100% 
  26. progress:[##################################################]100% 
  27.  
  28.  
  29. +--------------------------------------------------------------+ 
  30. | === 项目升级进行中,请稍候. we are running now.  === | 
  31. +--------------------------------------------------------------+ 
  32. 通过调用函数,把相应的参数导入即可 
  33. 进行备份,删除,转移,解压等操作. 
  34. /data/webapps/ops_apps/current 
  35. /data/webapps/ops_apps/backup/ops 
  36. /data/webapps/ops_apps/current 
  37. ########## 
  38. ops 
  39. ########## 
  40. /data/webapps/networkresourcemanage_apps/current 
  41. /data/webapps/networkresourcemanage_apps/backup/networkresourcemanage 
  42. /data/webapps/networkresourcemanage_apps/current 
  43. ########## 
  44. networkresourcemanage 
  45. ########## 
  46.  
  47.  
  48. +--------------------------------------------------------------+ 
  49. | === 复制替换修改配置文件  === | 
  50. +--------------------------------------------------------------+ 
  51. +--------------------------------------------------------------+ 
  52. | === cas project  === | 
  53. +--------------------------------------------------------------+ 
  54. "/home/testtomcat/bin/cas/datasource-appcontx.xml" -> "/data/webapps/cas_apps/current/WEB-INF/spring-configuration/datasource-appcontx.xml" 
  55.  
  56.  
  57. +--------------------------------------------------------------+ 
  58. | === networkresourcemanage project  === | 
  59. +--------------------------------------------------------------+ 
  60. "/home/testtomcat/bin/networkresourcemanage/sysconfig.xml" -> "/data/webapps/networkresourcemanage_apps/current/WEB-INF/classes/sysconfig.xml" 
  61. "/home/testtomcat/bin/networkresourcemanage/system-datasource-config.xml" -> "/data/webapps/networkresourcemanage_apps/current/WEB-INF/classes/datasource/system-datasource-config.xml" 
  62. "/home/testtomcat/bin/networkresourcemanage/datasource-appcontx.xml" -> "/data/webapps/networkresourcemanage_apps/current/WEB-INF/classes/com/iscreate/conf/spring/datasource-appcontx.xml" 
  63.  
  64.  
  65. +--------------------------------------------------------------+ 
  66. | === ops project  === | 
  67. +--------------------------------------------------------------+ 
  68. "/home/testtomcat/bin/ops/InterfaceURLConfig.properties" -> "/data/webapps/ops_apps/current/WEB-INF/classes/InterfaceURLConfig.properties" 
  69. "/home/testtomcat/bin/ops/sysconfig.xml" -> "/data/webapps/ops_apps/current/WEB-INF/classes/sysconfig.xml" 
  70. "/home/testtomcat/bin/ops/datasource-appcontx.xml" -> "/data/webapps/ops_apps/current/WEB-INF/classes/spring/datasource-appcontx.xml" 
  71. "/home/testtomcat/bin/ops/jbpm.hibernate.cfg.xml" -> "/data/webapps/ops_apps/current/WEB-INF/classes/jbpm.hibernate.cfg.xml" 
  72. "/home/testtomcat/bin/ops/hibernate.cfg.xml" -> "/data/webapps/ops_apps/current/WEB-INF/classes/hibernate.cfg.xml" 
  73.  
  74.  
  75. +--------------------------------------------------------------+ 
  76. | === 启动tomcat进程实例,大功告成,哈哈哈哈哈哈.  === | 
  77. +--------------------------------------------------------------+ 
  78. Using CATALINA_BASE:   /opt/tomcat/apache-tomcat-6.0.33_test 
  79. Using CATALINA_HOME:   /opt/tomcat/apache-tomcat-6.0.33_test 
  80. Using CATALINA_TMPDIR: /opt/tomcat/apache-tomcat-6.0.33_test/temp 
  81. Using JRE_HOME:        /opt/java/jdk1.6.0_26 
  82. Using CLASSPATH:       /opt/tomcat/apache-tomcat-6.0.33_test/bin/bootstrap.jar 
  83.  
  84.  
  85. +--------------------------------------------------------------+ 
  86. | === 查看后台日志,了解事实的真相. === | 
  87. +--------------------------------------------------------------+ 
  88. #view logs 
  89. progress:[##################################################]100% 
  90. progress:[##################################################]100% 
  91. 2012-12-24 20:06:18 org.apache.catalina.startup.HostConfig deployDirectory 
  92. 信息: Deploying web application directory docs 
  93. 2012-12-24 20:06:18 org.apache.coyote.http11.Http11Protocol start 
  94. 信息: Starting Coyote HTTP/1.1 on http-8080 
  95. 2012-12-24 20:06:18 org.apache.jk.common.ChannelSocket init 
  96. 信息: JK: ajp13 listening on /0.0.0.0:8009 
  97. 2012-12-24 20:06:18 org.apache.jk.server.JkMain start 
  98. 信息: Jk running ID=0 time=0/9  config=null 
  99. 2012-12-24 20:06:18 org.apache.catalina.startup.Catalina start 
  100. 信息: Server startup in 10875 ms