ram is always null in /api/resources ("My Machine" panel) whenever a GPU is present
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 72/100
Línea de trabajo
Empieza por pkg/xsysinfo/gpu.go e inspecciona GetResourceInfo() y la llamada existente a GetSystemRAMInfo() en la rama sin GPU. Mantén la RAM del host informada cuando se devuelvan los detalles de la GPU, junto con la VRAM en Aggregate; comprueba el endpoint de recursos o las pruebas pertinentes para confirmar que /api/resources devuelve ram distinto de null cuando hay una GPU presente.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
LocalAI version
v4.12.0 (15e37df9a468c798a5a511624f054057da4380a1), image localai/localai:latest-gpu-nvidia-cuda-13
Environment, CPU architecture, OS, and Version
- Docker on Linux (Ubuntu), host: Intel i9-14900KF (32 threads), 188GB RAM, NVIDIA RTX 4060 Ti (16GB VRAM)
nvidia-container-toolkit1.20.1,--gpus all- Confirmed the container has full, correct visibility into host RAM (
free -hand/proc/meminfoboth report the real 188GB inside the container, cgroupmemory.maxismax/unlimited)
Describe the bug
The "My Machine" panel in the web UI shows GPU, CPU, and disk info correctly, but RAM shows no data. Hitting the backend endpoint directly confirms it:
$ curl -s http://localhost:8080/api/resources
{"aggregate":{"total_memory":17175674880,...},"cpu":{...},"disk":{...},"gpus":[{...}],"ram":null,...}
ram is always null whenever a GPU is present. Tracing this through the source, it looks intentional rather than a detection failure: in pkg/xsysinfo/gpu.go, GetResourceInfo() takes a GPU-present branch that returns RAM: nil and instead reports VRAM totals under Aggregate, and only calls GetSystemRAMInfo() to populate RAM in the no-GPU fallback branch:
if <GPU detected> {
return &Resources{
RAM: nil,
Aggregate: AggregateMemoryInfo{
TotalMemory: aggregate.TotalVRAM,
...
},
}
}
// No GPU - fall back to system RAM
ramInfo, _ := GetSystemRAMInfo()
return &Resources{RAM: ramInfo, ...}
This means any machine with a GPU can never see host RAM info in /api/resources or the "My Machine" panel, even though the data is trivially available (GetSystemRAMInfo() already works correctly, as shown by the no-GPU branch using it).
To reproduce
- Run LocalAI with
--gpus allon any machine with an NVIDIA GPU. - Open the web UI → "My Machine" (or
curl localhost:8080/api/resources). - Observe GPU/CPU/disk are populated but
ramisnull.
Expected behavior
RAM should be populated alongside VRAM when a GPU is present — both are useful for sizing models (e.g. offloaded layers running on CPU RAM, or deciding how many models to keep warm), not just VRAM.
Additional context
Happy to test a fix — my setup bind-mounts /models, /backends, /configuration, /data onto a RAID0 NVMe array if that's a useful data point, though it doesn't seem related to this particular issue.
- Lenguaje dominante
- Go
- Estrellas
- 49.8k
- Forks
- 4.5k
- Merge medio
- 20 h 11 min
- PR fusionados (30 d)
- 350
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de mudler/LocalAI
-
[Bug] Qwen3.8-27b Uncensored Fails to Download due to 404Posiblemente ocupada @localai-org-maint-bot la tomó hace 1 día. Abiertobug unconfirmed
Dificultad 1/5 Menos de una hora Aptitud para principiantes 70/100
Los mantenedores suelen responder en 1 día
-
Realtime: ASR EOU language tags leak into the LLM conversation (unintended reply-language switching)Posiblemente ocupada @nexxtmobile la tomó hace 5 días. Abiertoarea/api bug unconfirmed
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
Los mantenedores suelen responder en 1 día
-
Open Responses API doesn't accept "output_text" as an input ItemPosiblemente ocupada @localai-org-maint-bot la tomó hace 24 días. Abiertobug unconfirmed
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
mudler/LocalAI#12337 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Gallery model audio-cpp-sortformer-diarization fails to install: SHA mismatch, reproducible across retriesQuizá libre de nuevo Un pull request para esta issue se cerró sin fusionarse. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
mudler/LocalAI#11995 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Agent pool Postgres DSN is logged in cleartext, including the password, while the auth DSN is redactedPosiblemente ocupada @localai-org-maint-bot la tomó hace 41 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
mudler/LocalAI#11991 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de mudler/LocalAI
Issues similares
-
[Bug]: APIGW request ID headers are inconsistent between server and clientPosiblemente ocupada @zouxingyuks la tomó hoy. Abiertoproduct/backlog
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
TencentBlueKing/bk-nodemgr#3782 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 91/100
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
praetorianer777/Dynamo#53 ·
Los mantenedores suelen responder en 1 día
-
internal test setup
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
SAP/terraform-provider-scc#430 ·
-
internal test setup
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
SAP/terraform-provider-btp#1743 ·
Los mantenedores suelen responder en 1 día