Mac system installation and configuration tomcat steps

Source: Internet
Author: User

HTTPS://WWW.JIANSHU.COM/P/53AFED9941E9: Download open Apache Tomcat official website, select the desired version download:

Two: Store to local folder name of the peopleApacheTomcat, put in/Users/计算机名/Library/Directory under

Three: Start Tomcat openTerminalEnterApacheTomcatIn the directory wherebinDirectory under
1 $:cd/users/mymac/library/apachetomcat/bin
StartTomcat
1 $:./startup.sh
is because the user does not have permissions and is unable to execute. Command requiredchmodModifybinUnder the directory.shPermissions, does not appear stating start success
1 $:chmod u+x *.sh
After modification, execute the start command again:./startup.shCan be started, the interface is as follows

Verify that the installation succeeded in entering the browser address bar:http://localhost:8080(or enter your computer in your mobile browser.)IP+ port number can also be accessed) displays the following interface:

Four: Close Tomcat
1 $:./shutdown.sh
View Tomcat version Information
1 $:sh catalina.sh version
V: APACHETOMCAT directory structure:

1>bin: Storing tomcat command 2>conf: Storing tomcat configuration information, the Server.xml file inside is the core configuration file 3>lib: Jar packages and technical support packages (such as Servlets and JSPs) that support the operation of the Tomcat software 4>logs: Log information at run time 5>temp: Temp directory 6>webapps: Shared resource file and Web App directory 7>work: The running directory for Tomcat. The temporary files generated by the JSP runtime are stored here to modify the port number the default port of the server is 8080, or it can be changed to a custom port, in order to avoid conflicts with the system port, must be set to more than 1024, For example, set to 8888 in Notepad to open the Server.xml file in the Apachetomcat conf directory, change the port value of the following statement to the custom port number 8080: (for example, 8020)
1 <connector port="8020" protocol="http/1.1 " 2           connectiontimeout="20000"3           redirectport="8443  " />
After restarting the server, input localhost:8080 is not valid, you need to enter localhost:8020 to open the server interface. The password is set inconfof the Catalogtomcat-users.xmlIn the file</tomcat-users>Add the following code to the above:
1 <role rolename="Manager-gui"/>2 <user username=" Tomcat " password="tomcat" roles="Manager-gui"/ >3 ---
BecausexmlThe tags are closed and restartedtomcat. Re-openhttp://localhost:8080ToTomcatMain interface, clickManager AppEtc button account and password inputtomcatCan Login

Mac system installation and configuration tomcat steps

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.