Changes

Jump to: navigation, search

Processes in D state

3 bytes removed, 21:10, 12 June 2006
m
Minor spelling fixes, some rewording and reformatting
If there are a lot of processes in D state in your system, then something is wrong with it.
 What is "'''D state" ''' and a process state in generallygeneral? A process in Linux can be in several states: runing staterunning, sleeping state and others, etc. Running process runs on a CPU just now, Sleeping sleeping process waits for its turn on CPUor for some other event. Using <tt>ps </tt> command you can obtain information about state of each process in the system: STAT column shows that:
<pre>
[root@dhcp0-56 ovz-utils]# ps a
PID TTY STAT TIME COMMAND
4975 tty1 Ss+ 0:00 /sbin/mingetty tty1
</pre>
First big '''S''' stands for Sleeping, '''R''' stands for runingrunning ("+" means that the process is foreground and small "s" means that the process is session leader, but it isn't is not relevant in our discussionfor this article). '''D ''' state occurs then the process is in uninterruptable uninterruptible disk sleep. This state is bad, because you can't do anything with the process in D state.Fortunately, process normally remains in such state not for so long.If But if you have a heap of D state processes than then some logic in system is disrupt. The If that is happening, the very important thing then is to determine,where this unlucky sleep occurs. It is easy to do with ps command with ''l'' option. WCHAN column shows the name of the kernel function wherethe process is sleeping:
<pre>
[root@dhcp0-56 ~]# ps axl | grep D
F UID PID PPID PRI NI VSZ RSS WCHAN STAT TTY TIME COMMAND
vass 13478 7.2 0.0 1732 624 pts/1 D+ 17:36 0:00 find ./
</pre>
Then {{Note|In case you have problem with the D state processes , always attach this information to the report, that you send to developers.}}
[[Category: Troubleshooting]]

Navigation menu