Unix SVR4 (OpenSolaris and Illumos Distributions) Memory Management
Unix SVR4 (OpenSolaris and Illumos Distributions) Memory Management
Introduction to UNIX
UNIX Memory Management
UNIX Memory Management Strategies
Swapping
Virtual Memory
Demand Paging
Kernel Memory
Conclusion
Introduction to UNIX
UNIX is a portable, multi-tasking and multi-user operating
system.
Portable: runs on many different hardware architectures
(Intel x86, HP PA-RISC, PowerPC, IBM S/390, etc.).
Preemptive multi-tasking: several programs can run at the
same time (time slices, interrupts, and task switching).
Multi-user: many users can share the computer system at
the same time.
UNIX Memory Management
Memory is an important resource in computer.
Memory management is the process of managing the
computer memory which consists of primary memory and
secondary memory.
The goal for memory management is to keep track of which
parts of memory are in use and which parts are not in use, to
allocate memory to processes when they need it and de-
allocate it when they are done.
UNIX memory management scheme includes swapping and
demand paging.
UNIX Memory Management Strategies
Overlays
Program will be place into memory during execution.
However, a large program will divide into small pieces and loading the
pieces as they needed.
Overlays will replace the new pieces with the program which is unused.
UNIX is using this technique to run a new program by fork the running
process which is also known as fork-exec.
Swapping
Swapping consists of bringing in each process in physical memory
entirely and running it.
When the process is no longer in use, the process will be terminated or is
swapped out to disk.
Swapping•
The process of moving some pages out
of main memory and moving others in,
is called swapping.
A page fault occurs when the CPU
tries to access a page that is not in
main memory, thus forcing the CPU to
wait for the page to be swapped in.
Since moving data to and from disks
takes a significant amount of time, the
goal of the memory manager is to
minimize the number of page faults.
Virtual Memory
As the size of frames and pages are the same, any logical
page can be placed in any physical frame of memory.
PAGE REPLACEMENT
The page frame data table is used for page replacement
Pointers are used to create lists within the table
all available frames are linked together in a list of free frames available for
bringing in pages
when the number of available frames drops below a certain threshold, the kernel
will steal a number of frames to compensate
System V Release 4 (SVR4)
SVR4, developed jointly by AT&T and Sun Microsystems, combines features
from SVR3, 4.3BSD, Microsoft Xenix System V, and SunOS.
It was almost a total rewrite Common facilities of the System V kernel and
produced a clean, if complex, implementation.
OpenSolaris
IS an open source computer operating system based on Solaris created
by Sun Microsystems.
Illumos
is a free and open-source Unix operating system.
It derives from OpenSolaris, which in turn derives
from SVR4 UNIX and Berkeley Software Distribution (BSD).
illumos comprises a kernel, device drivers, system libraries, and utility
software for system administration.
This core forms the basis of several operating system distributions
SVR4 and Solaris use two separate schemes:
paging system
provides a virtual memory capability that allocates
page frames in main memory to processes
REF1// http://self.gutenberg.org/articles
REF2//www.ukessays.com/essays
Os Internals & design --- William Stallings2.
The design of the unix operating system --- Maurice J.
Bach prentice