Re: [PATCH v4] Weighted Interleave Auto-tuning

From: Honggyu Kim
Date: Sun Feb 02 2025 - 08:44:19 EST


Hi Gregory,

On 2/2/25 01:49, Gregory Price wrote:
Hi Honggyu,

On Fri, Jan 31, 2025 at 11:23:34PM +0900, Honggyu Kim wrote:
Sorry for jumping into this discussion a bit late, but IMHO, setting a
newly onlined node's weight to 1 can possibly make the entire weight
ratio unbalanced.


This is only the default for either:
a) Manual Mode
b) Auto Mode - when HMAT/CDAT data is missing

In manual mode, the node weight in /sys/kernel/.../nodeN is present
regardless of the online/offline state of the node - so it can be
set prior to that node being hotplugged. Since it's in manual mode,
it's expected the administrator knows when things are coming online
and offline, and they have a clear chance to change weights such that
a 1 is never perceived.

This may be true, but system admins can hot-plug some nodes without
considering about weighted interleaving. If weighted interleave is not
their major use cases, then they may not consider weight values
seriously, but some workloads might use some weighted interleave APIs
that use all nodes available.

This might be my imaginary scenario so if you think it's not realistic,
then you can just ignore.

Thanks,
Honggyu


In auto mode, the node goes "online" after HMAT/CDAT data is reported
so users will generally not perceive this default weight.

1. the auto mode set the weights as 10:5:1 for node{0-2}.
2. node2 is offlined, then recalculation makes it as 2:1 for node{0,1}.
3. the auto sysfs interface is set to 0 to make it manual mode.

If the user sets manual mode, they get manual mode. If they don't
want to manually adjust weights, don't set manual mode.

We can't stop users from doing silly things

~Gregory