- Process identifier
In
computing , the process identifier (normally referred to as the process ID or just PID) is a number used by someoperating system kernels (such as that of UNIX,Mac OS X orWindows NT ) to uniquely identify a process.In Unix-like operating systems, the PID of a newly created
child process is returned by thefork()
system call to the parent.The PID can be passed to process control functions like
orwaitpid()
to perform actions on the given process, and if the operating system haskill() procfs support the files in/proc/pid/
can be queried for information about the process.In Unix-like operating systems, there are two tasks with specially distinguished process IDs: "swapper" or "sched" has process ID zero and is responsible for
paging , and is actually part of the kernel rather than a normaluser-mode process. Process ID 1 is usually theinit process primarily responsible for starting and shutting down the system. Originally, process ID 1 was not specifically reserved for init by any technical measures: it simply had this ID as a natural consequence of being the first process invoked by the kernel. More recent Unix systems typically have additional kernel components visible as 'processes', in which case PID 1 is actively reserved for the init process to maintain consistency with older systems.Under Unix, process IDs are usually allocated on a sequential basis, beginning at 0 and rising to a maximum value which varies from system to system. Once this limit is reached, allocation restarts at zero and again increases. However, for this and subsequent passes any PIDs still assigned to processes are skipped. Some consider this to be a potential security vulnerability in that it allows information about the system to be extracted, or messages to be covertly passed between processes. As such implementations that are particularly concerned about security may choose a different method of PID assignment. cite web | title =comp.unix.aix Frequently Asked Questions | url = http://www.faqs.org/faqs/aix-faq/part2/section-20.html | accessdate = 2008-07-21]
References
See also
Wikimedia Foundation. 2010.