LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-02-2010, 03:25 PM   #1
Rodnower
Member
 
Registered: Mar 2010
Posts: 54

Rep: Reputation: 15
ps not sum all CPU usage


Hello,
I run CentOS 5 on VMware 7.0.1, and when Firefox is up, computer's CPU (both on host and guest) is 99%~100% use. I watch this in GUI System Monitor In Linux, but when I open Processes tab (or respectively use ps aux command) that what I see
0.1 /usr/sbin/vmtoo
2.8 /usr/bin/Xorg :
0.1 metacity --sm-c
0.2 nautilus --no-d
0.1 /usr/lib/vmware
0.3 gnome-terminal
28.5 /usr/lib/firefo
13.4 gnome-system-mo
(names are cut)
sum: 45.5
all other is 0.0

In resources tab I see 99% CPU use. When I close Firefox CPU usage become be ~10%.

Some one can tell me how I can see more realistic image of CPU like it is in Windows for example?

Thank you for ahead.
 
Old 04-02-2010, 03:36 PM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 164Reputation: 164
Actually that is probably fairly accurate in reality. You can get a better running idea by using 'top'.
 
Old 04-02-2010, 04:11 PM   #3
Rodnower
Member
 
Registered: Mar 2010
Posts: 54

Original Poster
Rep: Reputation: 15
Thank you for replay.

Well, my problem isn't so deterministic...
Now I running Firefox again and it not use too much CPU.
Top actualy display the same (I mean sum of CPU usage) information like ps aux or System Monitor (but it is clear that top is more useful).

So, I gues, that in every case there is some processes that not dispalyed or "CPU leakage" if it is possible...
 
Old 04-02-2010, 04:45 PM   #4
Mr-Bisquit
Member
 
Registered: Feb 2009
Distribution: FreeBSD, OpenBSD, NetBSD, Debian, Fedora
Posts: 770
Blog Entries: 52

Rep: Reputation: 68
Run ps with the different options in the man page. Compare each with the output of top.
 
Old 04-02-2010, 07:38 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 15,533

Rep: Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041
Lies, damn lies and statistics. You can do anything you like with numbers - and it's even worse when you are using sampled data.
But in your case I suspect you are merely missing the "sys" component.

A cpu is considered 100% busy if there is no time when it is not busy. Sounds the same but isn't necessarily - especially with sampled data. And if (for example) kernel mode code is running half the time, only 50% is available to userland. But it's still 100% busy.
Maybe.

Short answer, don't try to be too exact.
 
1 members found this post helpful.
Old 05-12-2010, 03:24 PM   #6
Rodnower
Member
 
Registered: Mar 2010
Posts: 54

Original Poster
Rep: Reputation: 15
Thank you all, I will try run ps with different options and be less exact...
 
  


Reply

Tags
centos, ps, resources


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
processes/CPU Usage/Mem Usage desktop wallpaper ceantuco Linux - Newbie 2 04-13-2009 01:14 PM
Why %CPU total not equal to cpu(s) usage? pii.ajah Linux - Server 2 12-02-2008 08:30 PM
getting realtime info on memory usage-cpu and harddrive usage steering Linux - Newbie 5 03-03-2005 08:43 PM
how to determine cpu usage, memory usage, I/O usage by a particular user logged on li rags2k Programming 4 08-21-2004 04:45 AM
Controlling CPU usage & memory usage Saravana babu Linux - Software 0 02-18-2004 05:55 AM


All times are GMT -5. The time now is 10:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration