Difference between Internal Fragmentation and External Fragmentation

ComputersComputer NetworkInternet

As processes are loaded and removed from memory, the free memory space is broken into little pieces. It happens after sometimes that processes cannot be allocated to memory blocks considering their small size and memory blocks remains unused. This problem is known as Fragmentation.

Internal Fragmentation

Memory block assigned to process is bigger. Some portion of memory is left unused, as it cannot be used by another process. The internal fragmentation can be reduced by effectively assigning the smallest partition but large enough for the process.

External Fragmentation

Total memory space is enough to satisfy a request or to reside a process in it, but it is not contiguous, so it cannot be used. External fragmentation can be reduced by compaction or shuffle memory contents to place all free memory together in one large block. To make compaction feasible, relocation should be dynamic.

Following are the important differences between Internal Fragmentation and External Fragmentation.

Sr. No.KeyInternal FragmentationExternal Fragmentation
1DefinitionWhen there is a difference between required memory space vs allotted memory space, problem is termed as Internal Fragmentation.When there are small and non-contiguous memory blocks which cannot be assigned to any process, the problem is termed as External Fragmentation.
2Memory Block SizeInternal Fragmentation occurs when allotted memory blocks are of fixed size.External Fragmentation occurs when allotted memory blocks are of varying size.
3OccurrenceInternal Fragmentation occurs when a process needs more space than the size of allotted memory block or use less space.External Fragmentation occurs when a process is removed from the main memory.
4SolutionBest Fit Block Search is the solution for internal fragmentation.Compaction is the solution for external fragmentation.
5ProcessInternal Fragmentation occurs when Paging is employed.External Fragmentation occurs when Segmentation is employed.
raja
Published on 28-Nov-2019 11:37:17
Advertisements