Change Reserved Disk Space in Linux

Change Reserved Disk Space in Linux

The Linux operating system reserves a percentage of disk space when mounting a partition. This is done to allow the root user to log in even when the disk is full.

This reservation, while useful, may seem like a waste of space, especially on additional disks where the need for space may take priority over the root user's ability to log in.

To adjust the amount of reserved space, you can use the command: 

  1. tune2fs
For example, to reserve only 2% of the total disk space, you can run:
  1. sudo tune2fs -m 2 /dev/partition

The parameter 

  1. -m 2
indicates that the reserved space will be 2%. You can adjust this value according to your needs, using values such as:
  1. -m 1

* will reserve 1% 
  1. -m 0 

* will not reserve any space at all

Alert
Please note that reducing the reserved space on the operating system disk is not recommended, as it may affect system stability and performance. However, on additional disks where space may be more critical, this modification can be done without any issues.

It is always recommended to carefully evaluate the system's needs before making changes to the storage configuration.