The overall disk usage in the df -h --total output is calculated by summing up the total size, used space, and available space across all mounted file systems. Here's how it works:
- Total Size: This is the sum of the sizes of all mounted file systems.
- Used Space: This is the total amount of disk space that is currently being used across all mounted file systems.
- Available Space: This indicates how much disk space is still free and can be used.
The percentage of disk usage is calculated using the formula:
Used Percentage = (Used Space / Total Size) * 100
The -h option makes the output human-readable, displaying sizes in KB, MB, or GB. The --total option adds a final line that summarizes the total usage across all file systems.
