We have a program and we needs to run it. When it is started, a process is generated. Thus a process is a running instance of a program. Programs/services like Apache, mysql etc. usually generates multiple instances of program, in other words, multiple processes to handle the tasks assigned to them.
Different process states
1. Running:
Processes that are running in the system are called running processes. In most systems, at a time only one process runs.
2. Sleeping:
A process that is not running and is sleeping is called a sleeping process. This is inturn divided into two:
2.1 Interruptible:
It defines a sleeping process that is waiting for a signal from another process. It will change to running state anytime.
2.2 Uninterruptible:
A process that is waiting for a hardware condition to occur and is in a blocked state.
3. Stopped:
A process that is stopped by another process. This can be restarted.
4. Zombie:
A process that has completed its execution, but has entry in the process table is called Zombie process.
How a zombie process is generated:
Every process other than init has a parent process. So when the execution of a child process is complete, it releases all resources and memory and will be terminated. Then a signal is passed to the parent process indicating the status of that child process. Till the parent process receives that signal and confirms the termination of child, its entry will be in process table, which will make it a zombie process. In some cases, the parent gets killed due to some reasons and as a result wait call issued by parent will lose track of child process status. In that case the zombie process will remain in system until reboot.
Zombie processes are completely harmless, as it consumes no memory or resources and will just possess a simple entry in process table.
Tuesday, March 13, 2012
overview of linux processes
3:25 PM
linux basics, linux process overview, linux process states, linux processes, understanding linux process
No comments
Subscribe to:
Post Comments (Atom)






0 comments:
Post a Comment