-www.linuxidc.com ~]# ln-sf/usr/local/tomcat/bin/startup.sh/usr/bin/tomcat-up [Root@l-www.linuxidc.com ~]# Ln-sf/usr/local/tomcat/bin/shutdown.sh/usr/bin/tomcat-down ② Modify the/etc/profile file to set the variable catalina_home that the Tomcat service needs to use. [root@l
Configure the Access.log log------------------------------for the Tomcat containerCompile the Server.xml file,Unpackwars= "true" autodeploy= "true"Xmlvalidation= "false" Xmlnamespaceaware= "false" >The following information is appended below:Prefix= "localhost_access." suffix= ". Log" pattern= "combined"Resolvehosts= "false"/>Handling Tomcat unnecessary logs----------------------------------------In the
Details of the Tomcat log systemSynthesis: Tomcat-related log filesCataline engine log file, file name Catalina. Date. LogTomcat under the internal code is thrown out of the log, file name localhost. date. log (JSP page internal Error exception, Org.apache.jasper.runtime.HttpJspBase.service class thrown, log information is in the file!) )
Tomcat project deployment method: tomcat project deployment
Method 1:In the Conf directory of Tomcat, add the following to the
The Reloadable = "true" attribute indicates that files are automatically loaded when there is a change, that is, hot loading. In large web projects, we recommend that you do not use hot loading, which will greatly degrade system perform
auto start
(1) set tomcat1 to start automatically
Copy the/usr/local/tomcat1/bin/catalina. sh file to the/etc/init. d directory and change it to tomcat1.
# Cp/usr/local/tomcat1/bin/catalina. sh/etc/init. d/tomcat1
Modify the/etc/init. d/tomcat1 file and add the red part to the file:
# Vi/etc/init. d/tomcat1
Enter the following content in the first line (otherwise, an error occurs:
Eclipse startup Tomcat may cause the following error to pop up:The main reason is that Tomcat is not configured and the solution is as follows:First step: Windows->preference->server->runtime environment then choose the Tomcat version you installed, then next, choose the Tomcat installation path, FinishThe second step:
problem
Each time Tomcat starts, the following log files are automatically produced in the logs directory, and a file of the corresponding date is generated daily, resulting in numerous log files:
Localhost.2012-07-05.txt
Catalina.2012-07-05.txt
Manager.2012-07-05.txt
Host-manager.2012-07-05.txt
Purpose
Tomcat logs are exported to the same file.
Modify Steps
Ope
Reprint Address: http://blog.csdn.net/li_xiao_ming/article/details/21514637
problem
Each time Tomcat starts, the following log files are automatically produced in the logs directory, and a file of the corresponding date is generated daily, resulting in numerous log files:
Localhost.2012-07-05.txt
Catalina.2012-07-05.txt
Manager.2012-07-05.txt
Host-manager.2012-07-05.txt
Purpose
, because the default site is not specified, it cannot be accessed when the IP is entered directly.
So add D:\Tomcat5.5\conf\Catalina\localhost\ROOT.xml.Content such as
This can be implemented to enter the domain name to a site, enter the IP on the default to d:/tomcat5.5/portal this site
But, however, the problem arose.
These two sites start to consume quite a memory, Tomcat memory settings I have set to 1
Background:
Load balancing was implemented with Nginx and two Tomcat, and Tomcat ports (8080 and 8090) were closed in the firewall, and only 80 ports were opened externally. The Nginx configuration is as follows:
Upstream Tomcatcluster {
Server
: 8080;
Server
: 8090;
}
Server
{
Listen 80;
server_name dev.xjj.cn
......
Location/{
......
Location ~*/
/servlet/{
Include pro
Come to the ~~~~~ our "Weaver"--tomcat came, the cowherd wait for it! Ha ha!First, install Tomcat
: http://tomcat.apache.org/download-70.cgi
Left: The version of Tomcat is selected, for example Tomcat 7. On the right you can choose a different installation version, the red box is the ZIP inst
. ApplicationDispatcher. processRequest (ApplicationDispatcher. java: 486)
Atorg. apache. catalina. core. ApplicationDispatcher. doForward (ApplicationDispatcher. java: 411)
Atorg. apache. catalina. core. ApplicationDispatcher. forward (ApplicationDispatcher. java: 338)
At
......
The code is written as follows:
Onclick = "returnconfirm ('Are you sure you want to delete this repository? ') "/>
In the fi
main program running period. Therefore, if your application has a class, the permgen space error may occur. This error is common in the web server pre-processing JSP.Compile. If your web app uses a large number of third-party jar files and the size exceeds the default JVM size (4 MB), this error message is generated.
Solution:
1. manually set maxpermsizeModify tomcat_home/bin/Catalina. BAT (Catalina. Sh i
First of alldowloadSource and import intoEclipseIn,The level of code code after the import is as shown. Let's take a quick look.TomcatThe structure of the source code.javaxThis package is mainly aboutjava EENormative, such asServletWait, it's not our main analysis. Need to analyze aOrg.apacheSub-Package under,whichCatalinais important in thatTomcatThe boot is in the package under theStartupUnder the bag,catalina also defines
created based on the above configuration, and StandardContext will be used as a Child of the Host (can be found in Catalina. in the createStartDigester method, check how to parse the server. xml), context is started by the parent container host during tomcat startup.
Yes, I see this figure and it seems like I have known each other. This is the initialization of Context, because a context instance in
package will automatically install a startup script for the administrator:/etc/ Init.d/tocat* uses this script to cause an attacker to gain system root privileges through a low privilege tomcat user.
# Run The catalina.sh script as a daemon
Set +e
Touch "$CATALINA _pid" "$CATALINA _base"/logs/catalina.out
Chown $TOMCAT
with the operation of Tomcat, Catalina.out files will grow larger, although Tomcat will generate a Catalina.ymd.log file every day, but Catalina.out main file is still increasing, need to catalina.out by the day, to find a bit on the Internet, see an articleThe rotating catalina.out in Tomcat 5.5 using Cronolog is configured with the company's
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.