tomcat一直在linux中无法随机启动服务,经过反复的修改终于在晚上调通。
vi /etc/rc.local
#!/bin/sh # # This script will be executed *after* all the other init scripts. # You can put your own initialization stuff in here if you don't # want to do the full Sys V style init stuff. touch /var/lock/subsys/local #tomcat export JDK_HOME=/usr/java/jdk1.6.0_22 export JAVA_HOME=/usr/java/jdk1.6.0_22 /usr/local/tomcat/bin/startup.sh #ssh /etc/init.d/sshd start #vsftpd /etc/init.d/vsftpd start
除了tomcat,其他的只要把启动参数写入rc.local就好。
解决Linux下Tomcat随机启动问题
本文介绍了一种在Linux环境下确保Tomcat服务能够稳定启动的方法。通过修改rc.local文件,配置JDK_HOME和JAVA_HOME环境变量,并执行startup.sh脚本来实现。此外,还涉及了SSH和VSFTP等服务的启动配置。
679

被折叠的 条评论
为什么被折叠?



