OS-Memory Management in Unix

The Unix memory system has been based on a standard and relatively simple model. Earlier unix systems used swapping in order to maintain multiprogramming. Each process was loaded into memory(as three segments) in its entitely by means of a system process called the swapper using a first-fit allocation method. If insufficient spaces were available to load the process currently in memory

Current version of Unix use virtual paging for memory management, using a typical page size of 4k bytes. In order to maintain system a deamon process (every 250 msecs) in order to check if there are sufficient page frames free as defined by two system parameters, which we will call minframe & maxframe. When the paging daemon finds that the number of free frames is less than minframe, it begins to remove pages using a clock algorithm. It will continue to do this until the number of free frames rises to at least the maxframe value. Typical values for minframe & maxframe are 25 & 40 respectively. Additionally, the page fault rate is monitored and if it becomes excessive, the system may remove whole process from memory to reduce the competition for pages. Processors are selected for this on an LRV basis, is the longer the process has been resident without being refrenced the greater its chance of being evicted.
Share this article :
Copyright © 2012. Best Online Tutorials | Source codes | Programming Languages - All Rights Reserved