What is the performance impact of D state processes

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

What is the performance impact of D state processes

satish
Dear Erman,

I could see many sites explaining about D state processes.But how processes with D state will affect performance?It will be helpful to all

Thankyou
Reply | Threaded
Open this post in threaded view
|

Re: What is the performance impact of D state processes

ErmanArslansOracleBlog
Administrator
First of all, the processes waiting with an uninterruptable sleep state (D state) , are included in the calculation of Linux Load average. I have already seen these.. When a unrecoverable failure arises NFS disk path and if that disk is used by the process, you will see the D states, and you will see that your Load Average goes high.. So, Linux includes processes in uninterruptible sleep states to its load average..Yes it is so, even if we think that load average calculates running and ready-to-run processes only and these type of processes are usually in wait for DISK I/O..  The design is implemented in this way because, uninterruptable sleeps by concept, can lead a blocking system, as you know these processes can not be kill or stopped before they get what they are waiting for..

So, if you have D state processes, you can expect a high load average..

In Linux, load average is calculated by not only measuring the cpu demand, but  also I/O demand + uniterruptable tasks.. So it is not a cpu load average but system load average.
 
Cpu utilization is another thing.

In Linux there are hunderts of codepaths that set TASK_UNINTERRUPTIBLE.
So the question -> Should we expect a performance degradation caused by D state proceeses? -> is hard to answer.
It is related with the cause of D state processes..
If the cause is related with a commonly used device or something, then yes, we will feel a performance degradation.. It may goes to hang as well.

But if it is caused by a rarely used resource like NFS, then no.. We may see a high load average but we may still work with a proper performance.