From a023edfa5bc1982ba5c6365ea2e36c6dfc48a9ef Mon Sep 17 00:00:00 2001 From: Galigator Date: Mon, 20 Apr 2026 15:19:57 +0200 Subject: [PATCH] [bugfix] Use only onlines CPUs in lscpu (#40161) Signed-off-by: kse Co-authored-by: kse --- vllm/utils/cpu_resource_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vllm/utils/cpu_resource_utils.py b/vllm/utils/cpu_resource_utils.py index bf3d84fb68d..4a56e7f6433 100644 --- a/vllm/utils/cpu_resource_utils.py +++ b/vllm/utils/cpu_resource_utils.py @@ -155,7 +155,7 @@ def _get_cpu_list() -> list[LogicalCPUInfo]: return [LogicalCPUInfo(i, i, 0) for i in range(cpu_count)] lscpu_output = subprocess.check_output( - "lscpu -J -e=CPU,CORE,NODE", shell=True, text=True + "lscpu --json --extended=CPU,CORE,NODE --online", shell=True, text=True ) # For platform without NUMA, replace '-' to '0'