Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Java Tomcat eats a lot CPU!

Posted on 2014-12-22
1
Medium Priority
?
289 Views
Last Modified: 2014-12-31
Hi All,

I have 02 servers running Tomcat, with each server: 04 x CPUs, 16GBRAM, 300GB HDD.

OS: CentOS 6.6 and Flatform using: Liferay

Parameters for configure files:

1. [root@tcs1 ~]# more /usr/tomcat/apache-tomcat-7.0.42/bin/setenv.sh
AVA_OPTS="$JAVA_OPTS -Dfile.encoding=UTF8 -Dorg.apache.catalina.loader.WebappClassLoader.ENABLE_CLEAR_REFERENCES=false -Duser.timezone=Asia/Saigon -server -d64 -XX:NewSize=1g -XX:MaxNewSize=1g -Xms5g
-Xmx5g -XX:PermSize=1536m -XX:MaxPermSize=1536m -XX:SurvivorRatio=20 -XX:TargetSurvivorRatio=90 -XX:MaxTenuringThreshold=15 -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:ParallelGCThreads=4 -XX:Reserved
CodeCacheSize=512m -XX:+CMSParallelRemarkEnabled -XX:+CMSCompactWhenClearAllSoftRefs -XX:CMSInitiatingOccupancyFraction=85 -XX:+CMSScavengeBeforeRemark -XX:+CMSConcurrentMTEnabled -XX:+BindGCTaskThread
sToCPUs -XX:+UseFastAccessorMethods -XX:ParallelCMSThreads=1 -XX:+UseCompressedOops -XX:+DisableExplicitGC -XX:-UseBiasedLocking -Djava.net.preferIPv4Stack=true -XX:+UseLargePages"

2. /usr/tomcat/apache-tomcat-7.0.42/conf/server.xml
......
......
 <Connector executor="tomcatThreadPool"
               port="8080" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="8443" />
......
......

CPU can eat ~30% with connections connect to the Tomcat Server (~5 connections) & grow up rapidly 90% with 30-50 CCU.

Please give me some advices for troubleshooting issues above and how to solve this problem.

Thks in advance.
0
Comment
Question by:ldvhai
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 23

Accepted Solution

by:
Michael Fowler earned 1000 total points
ID: 40514316
This probably caused by one of the sites you have running. Have a look at this similar question

http://www.experts-exchange.com/Programming/Languages/Java/Q_28410915.html

You can use MiddlewareMagic to diagnose the problem
http://middlewaremagic.com/weblogic/?p=2281
0

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Containers like Docker and Rocket are getting more popular every day. In my conversations with customers, they consistently ask what containers are and how they can use them in their environment. If you’re as curious as most people, read on. . .
In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller singl…
The goal of the tutorial is to teach the user how to make an account for Skype and brief over view of all the options. There are three parts in this series.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question