<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>8587</bug_id>
          
          <creation_ts>2005-12-04 00:39:49 +0300</creation_ts>
          <short_desc>top shows bogus CPU usage data</short_desc>
          <delta_ts>2006-08-29 21:32:25 +0400</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>procps</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Sergey Vlasov">vsu</reporter>
          <assigned_to name="Mikhail Efremov">sem</assigned_to>
          <cc>ldv</cc>
    
    <cc>sem</cc>
    
    <cc>thresh</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>33560</commentid>
    <comment_count>0</comment_count>
    <who name="Sergey Vlasov">vsu</who>
    <bug_when>2005-12-04 00:39:50 +0300</bug_when>
    <thetext>top из procps-3.2.5-alt4 выдаёт явно неверные данные об использовании процессора:

top - 00:34:07 up 32 min,  6 users,  load average: 0.26, 0.30, 0.45
Tasks: 104 total,   4 running, 100 sleeping,   0 stopped,   0 zombie
CPU0  :   8.0% user,   6.8% system,   0.3% nice,  84.8% idle
Mem:   1033456K total,  1020612K used,    12844K free,     4204K buffers
Swap:   401584K total,        0K used,   401584K free,   431092K cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND           
 5094 vsu       20   0    12   12    4 R 99.9  0.0   0:14.64 burnK7             
    1 root       8   0   476  476  424 S  0.0  0.0   0:04.38 init               

Числа в строке CPU0 явно не соответствуют ситуации, когда почти 100% CPU
занимает burnK7.  vmstat при этом показывает данные, соответствующие реальности.

При незагруженном процессоре тоже показывается чушь:

top - 00:35:31 up 33 min,  6 users,  load average: 0.66, 0.44, 0.48
Tasks: 103 total,   2 running, 101 sleeping,   0 stopped,   0 zombie
CPU0  :  11.3% user,   6.5% system,   0.3% nice,  81.8% idle
Mem:   1033456K total,  1020712K used,    12744K free,     4204K buffers
Swap:   401584K total,        0K used,   401584K free,   430856K cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND           
    1 root       8   0   476  476  424 S  0.0  0.0   0:04.38 init               
    2 root       9   0     0    0    0 S  0.0  0.0   0:00.01 keventd            
    3 root      19  19     0    0    0 S  0.0  0.0   0:00.00 ksoftirqd_CPU0     
    4 root       9   0     0    0    0 S  0.0  0.0   0:00.10 kswapd             

Ситуация, похоже, воспроизводится независимо от ядра (наблюдалась как минимум на
i586 с ядром 2.4.29-std-up-alt9 и на x86_64 с ядром 2.6.12-std26-up-alt4).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33568</commentid>
    <comment_count>1</comment_count>
    <who name="Konstantin Pavlov">thresh</who>
    <bug_when>2005-12-04 18:56:50 +0300</bug_when>
    <thetext>На 2.6.12-std26-smp-alt4 / procps-3.2.5-alt4 не воспроизводится -- показывает
вполне нормальные значения:

Без загрузки:
CPU0  :  0.0% us,  0.0% sy,  0.0% ni, 100.0% id,  0.0% wa,  0.0% hi,  0.0% si
CPU1  :  0.0% us,  0.0% sy,  0.0% ni, 100.0% id,  0.0% wa,  0.0% hi,  0.0% si
CPU2  :  0.0% us,  0.0% sy,  0.0% ni, 100.0% id,  0.0% wa,  0.0% hi,  0.0% si
CPU3  :  0.3% us,  0.0% sy,  0.0% ni, 99.7% id,  0.0% wa,  0.0% hi,  0.0% si

С ней:
CPU0  :  0.3% us,  0.0% sy,  0.0% ni, 99.7% id,  0.0% wa,  0.0% hi,  0.0% si
CPU1  : 100.0% us,  0.0% sy,  0.0% ni,  0.0% id,  0.0% wa,  0.0% hi,  0.0% si
CPU2  :  0.0% us,  0.0% sy,  0.0% ni, 100.0% id,  0.0% wa,  0.0% hi,  0.0% si
CPU3  :  0.0% us,  0.0% sy,  0.0% ni, 100.0% id,  0.0% wa,  0.0% hi,  0.0% si</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33569</commentid>
    <comment_count>2</comment_count>
    <who name="Konstantin Pavlov">thresh</who>
    <bug_when>2005-12-04 19:28:50 +0300</bug_when>
    <thetext>предыдущий коммент относился к x86_64 системе.

на CelM с 2.6.12-wks26-up-alt4 / procps-3.2.5-alt4 положение идентично описанию vsu.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33576</commentid>
    <comment_count>3</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2005-12-05 04:12:22 +0300</bug_when>
    <thetext>Что нужно сделать, чтобы это воспроизвести?
На i586 с 2.4.26-std-smp-alt13 и на x86_64 с 2.6.12-std26-smp-alt4 у меня всё OK.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33582</commentid>
    <comment_count>4</comment_count>
    <who name="Konstantin Pavlov">thresh</who>
    <bug_when>2005-12-05 12:51:43 +0300</bug_when>
    <thetext>Похоже, баг проявляется только на однопроцессорной машине.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33583</commentid>
    <comment_count>5</comment_count>
    <who name="Konstantin Pavlov">thresh</who>
    <bug_when>2005-12-05 13:24:14 +0300</bug_when>
    <thetext>После отката на procps-3.2.5-alt3 проблема не проявляется, вероятно, все дело в
&quot;- Applied Owl patch for top.&quot; у procps-3.2.5-alt4</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33604</commentid>
    <comment_count>6</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2005-12-05 21:55:10 +0300</bug_when>
    <thetext>Indeed.  Fixed in 3.2.5-alt5</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>