[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <032f82e9-552a-4ad8-aff7-717e6f38af43@huawei.com>
Date: Tue, 4 Nov 2025 20:00:05 +0800
From: Cai Xinchen <caixinchen1@...wei.com>
To: Michal Koutný <mkoutny@...e.com>
CC: <llong@...hat.com>, <tj@...nel.org>, <hannes@...xchg.org>,
<cgroups@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<lujialin4@...wei.com>
Subject: Re: [PATCH -next RFC 0/2] cpuset: Add cpuset.mems.spread_page to
cgroup v2
Therefore, when setting memory_spread_page, I also need to perform a
drop cache operation.
This way, there is no need to restart the service.
Some previous ideas, such as using procfs or set_mempolicy to change the
mempolicy of
non-current processes, could also achieve the goal after dropping the
cache. [1]
Of course, changing the current memory distribution does not necessarily
require dropping
the cache, but it will inevitably lead to a series of memory migrations.
[1]
https://lore.kernel.org/all/20231122211200.31620-1-gregory.price@memverge.com/
https://lore.kernel.org/all/ZWS19JFHm_LFSsFd@tiehlicka/
On 11/3/2025 9:39 PM, Michal Koutný wrote:
> On Mon, Oct 20, 2025 at 02:20:30PM +0800, Cai Xinchen <caixinchen1@...wei.com> wrote:
>> The MPOL_INTERLEAVE setting requires restarting the DataNode service.
>> In this scenario, the issue can be resolved by restarting the service,
> \o/
>
>> but I would prefer not to restart the DataNode service if possible,
>> as it would cause a period of service interruption.
> AFAICS, the implementation of cpuset's spread page works only for new
> allocations (filemap_alloc_folio_noprof/cpuset_do_page_mem_spread) and
> there's no migraion in cpuset1_update_task_spread_flags(). So this
> simple v1-like spreading would still require restart of the service.
>
> (This challenge of dynamism also a reason why it's not ready for v2,
> IMO.)
>
> HTH,
> Michal
Powered by blists - more mailing lists