tomcat开机自启
tomcat install
|
|
tar -xvzf /home/guojianwei/jdk-8u162-linux-x64.tar.gz -C /opt/
# cp -r jdk1.8.0_162 /usr/local/
# tar -xvzf apache-tomcat-8.5.29.tar.gz -C /opt/
# cp -r apache-tomcat-8.5.29 /usr/local/
# ll /usr/local/
# cd /usr/local/
# mv apache-tomcat-8.5.29 tomcat
# cd /usr/local/tomcat/bin/
# cp /usr/local/tomcat/bin/catalina.sh /etc/init.d/tomcat
vim /etc/init.d/tomcat
|
# chkconfig: 2345 63 37 # description: tomcat server init script # Source Function Library /etc/init.d/functions JAVA_HOME=/usr/local/jdk1.8.0_162 CATALINA_HOME=/usr/local/tomcat |
# chmod 755 /etc/init.d/tomcat
# chmod 755 /etc/init.d/functions
# chkconfig --add tomcat
# chkconfig tomcat on
# service tomcat start
# ss -tunlp | grep -v grep |grep 8080
浙公网安备 33010602011771号