Tomcat set boot on Linux

Source: Internet
Author: User


1. Create a new file tomcat.sh and write the above content to the document. Java_home,webserver_path fill in according to the actual situation.

2. CP Tomcat.sh/etc/init.d/tomcat

3.sudo sysv-rc-conf Tomcat on

Check the Tomcat boot settings:

You can also find the start-up of Tomcat starting with s by going directly into the/ETC/RCX.D.

Here is a little more, the start of the S starting point indicates the boot start, the beginning of K indicates that the boot does not start.

4. If you want to cancel boot boot, sysv-rc-conf tomcat off

If you want to start an item to delete tomcat,sysv-rc-conf Tomcat remove

5. Restart the machine.

Check if Tomcat is really listening on the port:

Netstat-nltp|grep <tomcat Port >

6. You can finally manage Tomcat in the following way.

Start:/etc/init.d/tomcat start

Close:/etc/init.d/tomcat stop

No longer need to go to a layer of directories to find startup.sh or catalina.sh.




Tomcat set boot on Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.