Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
disk wait "D" state = not idle?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9679
Location: almost Mile High in the USA

PostPosted: Sat Jun 11, 2022 1:38 am    Post subject: disk wait "D" state = not idle? Reply with quote

I was watching my PC as it rsynced from RAID5 on one machine to a single disk on another. Slow mechanical disks, mind you. Anyway as I was running 'top' I noticed that processors' idle time was not near 100% as surely the machine was starving for data trying to read from slow hard disks. This time was accounted for in the 'Wait' column which indeed it was waiting for the disks.

But shouldn't the processes be sleeping while it waits, and an interrupt will occur when Linux finally is able to return the requested data?

Almost seems like the processes are polling for the disk to come back with data. While I wasn't running anything at the time, it seems that while the rsync process was waiting for data to come back from the disks, another process could preempt and do computation, and well, processes in wait should not be subtracting from idle time (of which the processor could be sleeping?)

Not sure if I'm reading 'top' correctly either. But seemed a bit odd or perhaps I'm missing something here. Perhaps it truly is spin loop waiting for data, maybe it's cheap network cards? Hmm...
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum