Solved

Unix server slowness

Posted on 2006-07-03
6
424 Views
Last Modified: 2012-06-21
We are running our web site on a unix server running Solaris 2.9, Apache 2.055 and Coldfusion MX 7.0.1.
Our web server hosted on this unix machine has slowed way down with the process that serves coldfusion pages (jrun) hogging the CPU around 30-50% bringing our web server to a crawl. (below is a snapshot of the top CPU processes). Are there any unix or coldfusion commands that can get a specific look at exactly what is causing this slowness i.e. see a more specific job or code that is exactly causing these problems. Running top or prstat isn't helpful since we know Jrun is hogging the cpu but not which specific code or jobs.
Thank you!

327 root     201   0   10  551M  471M cpu/0   30.4H 44.23% jrun
21599 cbeverly   1   9    0 1864K 1296K cpu/1    0:00  0.41% top
4102 webapp    18  29   10  144M   63M sleep    2:39  0.02% java
21559 apache     1  59    0   10M 3728K sleep    0:00  0.02% httpd
21597 apache     1  59    0   10M 3096K sleep    0:00  0.02% httpd
21534 apache     1  59    0   10M 3792K sleep    0:00  0.02% httpd
21548 apache     1  59    0   10M 3760K sleep    0:00  0.02% httpd
21581 apache     1  59    0   10M 3640K sleep    0:00  0.02% httpd
21574 apache     1  59    0   10M 3640K sleep    0:00  0.02% httpd
21587 apache     1  59    0   10M 3632K sleep    0:00  0.01% httpd
21535 apache     1  59    0   10M 3792K sleep    0:00  0.01% httpd
21582 apache     1  59    0   10M 3656K sleep    0:00  0.01% httpd
21573 apache     1  59    0   10M 3632K sleep    0:00  0.01% httpd
21571 apache     1  59    0   10M 3776K sleep    0:00  0.00% httpd
0
Comment
Question by:cbeverly
6 Comments
 
LVL 38

Accepted Solution

by:
yuzh earned 125 total points
ID: 17034421
You can try to use "top" or prstat or ""/usr/ucb/ps -uax | head -10"
to find out which process is eating the system resource, then use
"truss" to find out more details about the process.

man truss
to learn more details
0
 
LVL 1

Assisted Solution

by:shmukler
shmukler earned 125 total points
ID: 17035369
Try to look with DTrace which is avaiable is a separate module for 2.9.

You might want to play with scripts from http://users.tpg.com.au/bdgcvb/dtrace.html or other script collections available on google.

Otherwise, so understand exactly, one has to use profiling tools.

It not easy to say what's wrong without getting the whole picture. DTrace can help to localize the problem, if you are using JRun for Java there is a document covering profiling JRun with OptimizeIt and such tools.
0
 
LVL 1

Assisted Solution

by:bengtbj
bengtbj earned 125 total points
ID: 17043086
OK, it looks like your java engine is using up quite a lot of space and CPU time

The 2.39 is the amount of time on the kernel run queue, divided by two for every run queue cycle it has not been processed, something along those lines, and not really anything I could put in my answer here. 2.39 is not really bad, it just means it using a lot of CPU time (this depends off cause how long the java engine has been up as well). It might be worth to see if there are any other processes that are using up time, but remember that daemons are always on the run queue, so don’t get alarmed by finding syncd at a couple of hours, and don’t kill it, its job is to sync disks.

Also worth checking with normal performance tools such as iostat, vmstat, sar. Check Wait IO and page swapping, normally a good hint that something other then running low on CPU cycles. Also, if you have control over a test system, check to load the java application without any data, and then add just a bit of the data. Have seen java memory manager getting problems when building large tables or large number of objects. If that is the case I can’t help you much, not any good at java coding.
0
 
LVL 6

Assisted Solution

by:JJSmith
JJSmith earned 125 total points
ID: 17047448

I don't see any real evidence that your 2 CPU's are under any pressure. I would suggest you may need to look to the other 'balancing' components of memory and/or disk I/O if you system is running slowly.

It may also be that your application is 'contending' for the same resources - even though you machine has plenty of spare, the 'app' threads may be blocking each others access to the same objects. ( forcing serialized processing instead of parallel ).

Cheers
JJ
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

863 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

Need Help in Real-Time?

Connect with top rated Experts

28 Experts available now in Live!

Get 1:1 Help Now