Interview Questions - UNIX Memory Management
Why should I learn to solve UNIX Memory Management technical interview questions?
Learn and practise solving UNIX Memory Management technical interview questions and answers to enhance your skills for clearing technical interviews, HR interviews, campus interviews, and placement tests.
Where can I get technical UNIX Memory Management technical interview questions and answers with explanations?
IndiaBIX provides you with lots of fully solved UNIX Memory Management technical interview questions and answers with a short answer description. You can download UNIX Memory Management technical interview questions and answers as PDF files or e-books.
How do I answer UNIX Memory Management technical interview questions from various companies?
You can answer all kinds of UNIX Memory Management technical interview questions by practising the given exercises (short answer type). You can also find the frequently asked UNIX Memory Management technical interview questions with answers from various companies, such as TCS, Wipro, Infosys, CTS, IBM, etc.
Swapping: Whole process is moved from the swap device to the main memory for execution. Process size must be less than or equal to the available main memory. It is easier to implementation and overhead to the system. Swapping systems does not handle the memory more flexibly as compared to the paging systems.
Paging: Only the required memory pages are moved to main memory from the swap device for execution. Process size does not matter. Gives the concept of the virtual memory. It provides greater flexibility in mapping the virtual address space into the physical memory of the machine. Allows more number of processes to fit in the main memory simultaneously. Allows the greater process size than the available physical memory. Demand paging systems handle the memory more flexibly.
- It decides which process should reside in the main memory,
- Manages the parts of the virtual address space of a process which is non-core resident,
- Monitors the available main memory and periodically write the processes into the swap device to provide more processes fit in the main memory simultaneously.
A Map is an Array, which contains the addresses of the free space in the swap device that are allocatable resources, and the number of the resource units available there.
Address Units
1 10,000
This allows First-Fit allocation of contiguous blocks of a resource. Initially the Map contains one entry - address (block offset from the starting of the swap area) and the total number of resources.
Kernel treats each unit of Map as a group of disk blocks. On the allocation and freeing of the resources Kernel updates the Map for accurate information.