Ios-mac configuring Tomcat "Mac Environment configuration Tomcat"

Source: Internet
Author: User

Tomcat Configuration

1. Download the Tomcat configuration package on the website: http://tomcat.apache.org/download-70.cgi

2. After the download, the extracted entire folder renamed: Apachetomcat (this name casually), and then placed in a file directory, I put it in:/users/computer user name/library;

3. Open the terminal into the Bin folder directory in the Apachetomcat file;

4. Then start Tomcat, terminal input:./startup.sh, if prompted:-bash:./startup.sh:permission denied, the startup fails, requires terminal input: chmod u+x *.sh authorization;

5. After authorization again terminal input:./startup.sh, if shown, the start is successful;

6. Check whether the boot is successful, open in the browser: http://localhost:8080 "localhost can be replaced with your IP address", if the page is displayed, it has been started normally;

7. Close Tomcat, or in the Bin folder directory, terminal input:./shutdown.sh

folder Directory

1) Bin: Store 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 runtime

5) Temp: Temp directory

6) WebApps: Shared resource file and Web App directory

7) Work:tomcat running directory. The temporary files generated by the JSP runtime are stored here.

Modify Port number

The default port of the server is 8080, or it can be changed to a custom port, to avoid conflicts with the system port, must be set to more than 1024, for example, set to 8888

Open the Server.xml file under Apachetomcat's conf directory with Notepad, and change the port value 8080 of the following statement to a custom port number: (for example, 8020)

<connector port= "8020" protocol= "http/1.1"

connectiontimeout= "20000"

redirectport= "8443"/>

After restarting the server, input localhost:8080 is not valid, you need to enter localhost:8020 to open the server interface.

Password Settings

In the Tomcat-users.xml file of the Conf directory </tomcat-users> add the following code:

<role rolename= "Manager-gui"/>

<user username= "Tomcat" password= "Tomcat" roles= "Manager-gui"/>

Because the XML tags are closed, and you want to restart Tomcat. Re-open http://localhost:8080 to the Tomcat master interface, click on the Manager app button account and password enter Tomcat to login

Related reference: http://blog.csdn.net/feng2qing/article/details/60968548

Ios-mac configuring Tomcat "Mac Environment configuration Tomcat"

Related Article

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.