Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Inconsistent total capacity in CGI and statfs
The CGI and statfs system call where reporting different total capacities of the filesystem. The CGI monitoring was showing the total capacity of all hard drives, regardless of limits in HDD_LEAVE_SPACE_DEFAULT option. Meanwhile, statfs was showing total capacity as space available on all hard drives + actual used bytes for chunks (or the reported total capacity on all hard drives, whichever was lower). This commit tries to get rid of these discrepancies by discounting the HDD_LEAVE_SPACE_DEFAULT value towards the final capacity of a drive in the chunkserver. Both statfs and CGI will now show this capacity in the same way. Signed-off-by: Urmas Rist <[email protected]>
- Loading branch information