What's it waiting for? - Grin with cat attached — LiveJournal
Previous Entry Next Entry
What's it waiting for? Aug. 24th, 2004 05:52 pm
Is there any way of finding out from the unix (ok, linux) command line whether processes are CPU-bound or disk-bound? Or which is the major cause of (uptime-style) load on a box?

From: deliberateblank
Date: August 24th, 2004 - 05:35 pm (Link)
You could just run top and see what it's CPU use looks like. 100% user and it's CPU bound. Less and it's either a sleeper or waiting on something else.
From: wechsler
Date: August 24th, 2004 - 06:13 pm (Link)
Yeah, that was about as far as I'd got. I seem to be getting impressively high load with very little CPU usage.
From: reddragdiva
Date: August 24th, 2004 - 06:44 pm (Link)
The one time I've seen that on Solaris, it's been w13rd shit happening with TCP/IP - the web-censor sending incomplete packets and the network stack busy-waiting. So nothing shows in top (or, on Solaris, prstat) but the box is showing load averages in the thirties and forties and not being very responsive.

I assume iostat has useful things to say about performance.

Dumb question

From: babysimon
Date: August 24th, 2004 - 09:40 pm (Link)
It's not spending all its time swapping, is it?
(no subject) - xraycb
From: steer
Date: August 24th, 2004 - 10:28 pm (Link)
I can't really answer the question directly -- but I can say I had major problems with processes slowing down and acting as if the CPU was taking a huge hit (when it wasn't) when I was running a kernel with UDMA misconfigured. [I still get the same symptoms when copying to my mp3 player.]

Doubt that will help, but you never know.
From: fellcat
Date: August 25th, 2004 - 12:11 pm (Link)
man ps and see if any of options you can ask it to display are any good to you. I would find out myself, but the college is sadly lacking in Linux boxen.