0% found this document useful (1 vote)
767 views3 pages

Free Space Management

Free space management in operating systems is essential for efficient utilization of limited hard disk space, involving allocation and deallocation of memory blocks. Various methods such as Bitmap, Linked List, Grouping, and Counting are employed to track and manage free spaces. Each method has its own approach to maintaining a free space list, ensuring that the operating system can effectively handle file creation and deletion.

Uploaded by

abdullahzia180
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (1 vote)
767 views3 pages

Free Space Management

Free space management in operating systems is essential for efficient utilization of limited hard disk space, involving allocation and deallocation of memory blocks. Various methods such as Bitmap, Linked List, Grouping, and Counting are employed to track and manage free spaces. Each method has its own approach to maintaining a free space list, ensuring that the operating system can effectively handle file creation and deletion.

Uploaded by

abdullahzia180
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

FREE SPACE MANAGEMENT

Overview

As we know, there is limited space (hard disk) in our system. So, there should be
proper utilization of space or memory available in our system.

The Operating system works to allocate free space to the files when a file is
created. It also creates a free void space when a file is deleted from the system. For
doing all these tasks and managing spaces in our system, the operating system
works with the help of a free space management system and allocates and de-
allocates memory spaces simultaneously. In this article, we are going to learn
about these concepts

What is Free Space Management in OS?

There is a system software in an operating system that manipulates and keeps a


track of free spaces to allocate and de-allocate memory blocks to files, this system
is called a file management system in an operating system". There is a free space
list in an operating system that maintains the record of free blocks.

When a file is created, the operating system searches the free space list for the
required space allocated to save a file. While deletion a file, the file system frees
the given space and adds this to the free space list.
Methods of Free Space Management in OS

It is not easy work for an operating system to allocate and de-allocate memory
blocks (managing free space) simultaneously. The operating system uses various
methods for adding free space and freeing up space after deleting a file. There are
various methods using which a free space list can be implemented. We are going to
explain them below-

1 - Bitmap or Bit Vector

A bit vector is a most frequently used method to implement the free space list. A
bit vector is also known as a Bit map. It is a series or collection of bits in which
each bit represents a disk block. The values taken by the bits are either 1 or 0. If
the block bit is 1, it means the block is empty and if the block bit is 0, it means the
block is not free. It is allocated to some files. Since all the blocks are empty
initially so, each bit in the bit vector represents 0.

2 - Linked List

A linked list is another approach for free space management in an operating


system. In it, all the free blocks inside a disk are linked together in a linked list.
These free blocks on the disk are linked together by a pointer. These pointers of the
free block contain the address of the next free block and the last pointer of the list
points to null which indicates the end of the linked list. This technique is not
enough to traverse the list because we have to read each disk block one by one
which requires I/O time

3 - Grouping

The grouping technique is also called the "modification of a linked list


technique". In this method, first, the free block of memory contains the addresses
of the n-free blocks. And the last free block of these n free blocks contains the
addresses of the next n free block of memory and this keeps going on. This
technique separates the empty and occupied blocks of space of memory.
4 - Counting

In memory space, several files are created and deleted at the same time. For which
memory blocks are allocated and de-allocated for the files. Creation of files occupy
free blocks and deletion of file frees blocks. When there is an entry in the free
space, it consists of two parameters- "address of first free disk block (a
pointer)" and "a number 'n'".

You might also like