iotop's scraping loop looks like:

read_counters()
while running:
  read_counters()
  print delta
  sleep(delay)

So there are indeed two reads close to each other at startup.
You can see the first read in
http://repo.or.cz/w/iotop.git/blob/HEAD:/iotop/data.py#l372:

 372         # A first time as we are interested in the delta
 373         self.update_process_counts()

The first screen of output will be all zero or not depending on the
relative speed of iotop and the I/O generating process. So, all bets
are off.

This is to mimic "top -d<huge value>" which gives you an output right
away and _then_ starts the main loop.

There's always "iotop -o" to filter out zero values, so I don't know
if there's anything to fix here.

-- 
Guillaume



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to