Linux Learning Note May 15 task

Source: Internet
Author: User

16.4 Configuring Tomcat Listening 80 ports

Visit the website by default is 80 port, if is 8080 port, need to access IP plus port, want to implement without port can visit website, just modify Server.xml, configure as follows:

#vim/usr/local/tomcat/conf/server.xml

Connector port= "8080" protocal= "http/1.1" modified to Connector port= "" "Protocol=" http/1.1 "

#/usr/local/tomcat/bin/shutdown.sh

#/usr/local/tomcat/bin/startup.sh

View in progress, #ps aux | grep java

Viewing the listening port, #! Net

Stop Nginx,#/etc/init.d/nginx Stop

#/usr/local/tomcat/bin/shutdown.sh

#/usr/local/tomcat/bin/startup.sh//8005 port start slow, need to wait, start, open the page is fast;


16.5/16.6/16.7 Configuring the Tomcat virtual host

#vim/usr/local/tomcat/conf/server.xml//Add below </Host> below

Unpackwars= "true" autodeploy= "true"

Xmlvalidation= "false" Xmlnamespaceaware= "false" >

<context path= "" docbase= "/data/wwwroot/123.cn" debug= "0"

Reloadable= "true" crosscontext= "true"/>

</Host>

#wget Http://dl.zrlog.com/release/zrlog-1.7.1-baaecb9-release.war//war package automatically unzip, delete the war package, will also automatically delete the extracted directory

#mv zrlog-1.7.1-baaecb9-release.war/usr/local/tomcat/webapps/

#mv/usr/local/tomcat/webapps/Zrlog-1.7.1-baaecb9-release/usr/local/tomcat/webapps/zrlog


Browser Access ip:8080/zrlog/install/

#mv/usr/local/tomcat/weapps/zrlog/*/data/wwwroot/123.cn/


Set up a database to fill in the information above

Check if MySQL is started, #ps aux | grep MySQL

Go to MySQL, #mysql-uroot-paminglinux

Mysql>create database Zrlog;

Mysql>grant all on zrlog.* to ' Zrlog ' @127.0.0.1 identified by ' Aminglinux ';

Mysql>quit

#mysql-uzrlog-h127.0.0.1-paminglinux

Mysql>show databases;

Mysql>quit


Now visit Zrlog blog, need browser access to ip:8080/zrlog/, if cancel the/zrlog/, then do the following actions;

#vim/usr/local/tomcat/conf/server.xml //See docbase= "/data/wwwroot/123.cn"

#mkdir/data/wwwroot/123.cn

#mv/usr/local/tomcat/webapps/zrlog/*/data/wwwroot/123.cn/

Then bind the hosts,

#/usr/local/tomcat/bin/shutdown.sh

#/usr/local/tomcat/bin/startup.sh

To see if the 80,8009,8005 port is started, #!net

View a port that contains 80 characters, #netstat-LNTP | grep 80

Visit the website www.123.cn


16.8 Tomcat Log


#ls/usr/local/tomcat/logs//There are four types of files


Configuration Log

<valve classname= "Org.apache.catalina.valves.AccessLogValve"

directory= "Logs"

prefix= "123.cn_access" suffix= ". Log"

pattern= "%h%l%u%t &quot;%r&quot; %s%b "/>


Extended

Chuli Tomcat Document HTTPS://WWW.LINUSER.COM/FORUM.PHP?MOD=FORUMDISPLAY&FID=37

JAR, War package difference http://blog.csdn.net/lishehe/article/details/41607725

Tomcat Common configuration Rollup http://blog.sina.com.cn/s/blog_4ab26bdd0100gwpk.html

Resin installing 1 Tomcat standalone Multi-instance

2 Tomcat settings for JVM and number of connections

3 JMX Monitor Tomcat

4 JVM Performance Tuning monitoring Tool 5 GVM GC related


Linux Learning Note May 15 task

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.