Operating System - Linux
1822582 Members
3544 Online
109643 Solutions
New Discussion юеВ

Re: Top on RHEL3 vs RHEL4

 
SOLVED
Go to solution
joseph wholey
Regular Advisor

Top on RHEL3 vs RHEL4

Gents,

When I run TOP on a RHEL3 server with 8 cpu's, the output shows cpu0-7, and %age used. On RHEL4, same class server, it does not show individual cpu information. Is this by design? Any help would be greatly appreciated.

thx.
6 REPLIES 6
Steven E. Protter
Exalted Contributor
Solution

Re: Top on RHEL3 vs RHEL4

Shalom,

There have been fixes to top, so you will need to tell us whether you are on RH 4 update 4 or some earlier release.

top was changed for RH4 and has had a bug fix or two.

Note that the same class of server may also not be the same.

Lets say you have a pair of DL380's with maximum CPU's installed.

A server purchased in early 2005 will show up as two cpu's because it doesn't have hyperthreading capability nor does it have dual core cpus.

The same server purchased a year later in the summer of 2006 with maximum cpu's is going to show 8 cpus, because it does have hyperthreading, which creates two software cpu's for each hardware cpu and dual core, which gives it 4 hard cpu's and 8 cpu's on th e RH 4 update 4 top display.

So before you shoot at top, which may be the problem here, make sure you are comparing apples to apples.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
joseph wholey
Regular Advisor

Re: Top on RHEL3 vs RHEL4

Wait.... how should it show up in TOP. i.e. if I have 8 cpu's showing up in /proc/cupinfo, shouldn't TOP show me all 8 of those cpu's?
Furthermore, how do I know if the cpus in /proc/cpuinfo physical or dual core cpu's.
Steven E. Protter
Exalted Contributor

Re: Top on RHEL3 vs RHEL4

Shalom,

Well now you have narrowed it down.

I agree based on the new information you should be seeing more than 1 cpu in top.

Okay here we go.

top from RH 4 update 3 machine with 1 CPU with hypertreading enabled and the smp kernel.

top - 12:18:03 up 26 days, 20:45, 1 user, load average: 0.30, 0.11, 0.08
Tasks: 123 total, 1 running, 122 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.0% us, 0.2% sy, 0.0% ni, 99.8% id, 0.0% wa, 0.0% hi, 0.0% si
Mem: 1033204k total, 355704k used, 677500k free, 24444k buffers
Swap: 1048568k total, 70188k used, 978380k free, 68896k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1 root 16 0 2560 488 456 S 0.0 0.0 0:02.53 init
2 root RT 0 0 0 0 S 0.0 0.0 0:46.90 migration/0
3 root 34 19 0 0 0 S 0.0 0.0 0:02.44 ksoftirqd/0
4 root RT 0 0 0 0 S 0.0 0.0 0:47.70 migration/1
5 root 34 19 0 0 0 S 0.0 0.0 0:02.37 ksoftirqd/1
6 root 5 -10 0 0 0 S 0.0 0.0 0:00.14 events/0
7 root 5 -10 0 0 0 S 0.0 0.0 0:00.14 events/1
8 root 5 -10 0 0 0 S 0.0 0.0 0:00.00 khelper
9 root 14 -10 0 0 0 S 0.0 0.0 0:00.00 kacpid
35 root 5 -10 0 0 0 S 0.0 0.0 0:00.04 kblockd/0
36 root 5 -10 0 0 0 S 0.0 0.0 0:00.04 kblockd/1
37 root 15 0 0 0 0 S 0.0 0.0 0:00.55 khubd
46 root 15 0 0 0 0 S 0.0 0.0 0:52.13 pdflush
47 root 15 0 0 0 0 S 0.0 0.0 2:39.51 pdflush
49 root 6 -10 0 0 0 S 0.0 0.0 0:00.00 aio/0
50 root 6 -10 0 0 0 S 0.0 0.0 0:00.00 aio/1
48 root 15 0 0 0 0 S 0.0 0.0 5:30.53 kswapd0

Linux shalom2 2.6.9-34.ELsmp #1 SMP Fri Feb 24 16:54:53 EST 2006 i686 i686 i386 GNU/Linux

The same system with RH 3 update8 shows two CPU's.

The GUI system monitor display shows two cpus.

Talk about consistecy.

Its top. You had it right from the get go.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
joseph wholey
Regular Advisor

Re: Top on RHEL3 vs RHEL4

Stephen,

Sholom... you know where I can find this bug documented as well as resolution? '

Regards, Joe
TimMC
Advisor

Re: Top on RHEL3 vs RHEL4

In RHEL 4 while running top, try pressing "1". This should switch the views between a summary CPU view to seeing all the CPUs separately.
joseph wholey
Regular Advisor

Re: Top on RHEL3 vs RHEL4

Tim, that's excellent... Steven, what happened. thx.