Janus Chow created HDDS-12373:
---------------------------------
Summary: Change calculation logic for volume reserved space
Key: HDDS-12373
URL: https://issues.apache.org/jira/browse/HDDS-12373
Project: Apache Ozone
Issue Type: Improvement
Reporter: Janus Chow
The current logic for "hdds.datanode.dir.du.reserved" is as follows:
{code:java}
private long getRemainingReserved(){
return Math.max(reservedInBytes - getOtherUsed(), 0L);
} {code}
which means if OtherUsed() is larger than reservedInBytes, then
remainingReserved will be count to 0.
When we set a "hdds.datanode.dir.du.reserved" to 100GB, we actually want the
disk to spare 100GB in case of "SPACE not enough exceptions".
But normally servers have a system level block reservation, which is 5%. So for
a 10T disk, the system level reserved space is about 500GB, when we set the
configuration to 100GB, the "remaningReserved" is calculated as 0, so for
capacity and availabilty, reservation is not counted.
In current calculation logic ,in order to reserve a 100GB space, we need to set
configuration to "600GB" (500 + 100) or "0.06" (0.05 + 0.01 for percent).
This ticket is to change the logic of the reservation calculation to have a
more intuitive aspect for the users, thus no need to take care of the Other
usages.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]