mirror of
https://github.com/lemonade-sdk/lemonade.git
synced 2026-11-23 08:49:28 -10:00
codex/auto-model-source
7
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
d4f53e7dd3 |
Gate NVIDIA CUDA backends on a missing or outdated driver (#4066)
* Gate NVIDIA CUDA backends on a missing or outdated driver Detection fallbacks (DRM/nouveau and lspci on Linux, PCI vendor ID via Win32_PnPEntity on Windows) now flag NVIDIA GPUs that have no NVIDIA driver bound. Backends that require an NVIDIA GPU report "unsupported" when every detected NVIDIA GPU lacks the driver. llamacpp:cuda additionally reports "action_required" with a driver download link when the driver predates its CUDA 12.9.0 toolkit (576.02 on Windows, 575.51.03 on Linux). Neither state is chosen as the auto default, so llamacpp falls through to Vulkan; an explicit cuda selection is still allowed for an old driver. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LdWSB6ZjZctJ4yMjCV6nHm * Use the CUDA 12.x driver floor for the llamacpp:cuda minimum CUDA minor-version compatibility lets the CUDA 12.9 build run on any CUDA 12.0-era driver, so gate on 528.33 (Windows) / 525.60.13 (Linux) instead of the 12.9.0 toolkit's own 576.02 / 575.51.03 minimum. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LdWSB6ZjZctJ4yMjCV6nHm * Limit NVIDIA driver gating to CUDA-only rows and keep arch results Vulkan rows for sd-cpp, acestep, trellis, openmoss and thinksound list nvidia_gpu alongside cpu/amd_gpu, so the driver gate marked them unsupported whenever an NVIDIA card had no driver, removing the very fallback the gate is meant to steer to. Only rows whose sole device is nvidia_gpu are gated now. The gate also no longer replaces an unsupported-architecture result (e.g. Pascal on llamacpp:cuda): an old driver kept such rows unsupported instead of turning them into a selectable action_required. A missing driver still names the driver when the architecture is unknown, which is how a driverless card is detected. Docs: note the limits of minor-version compatibility and recommend the 12.9 toolkit's driver. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LdWSB6ZjZctJ4yMjCV6nHm * Tell users to restart Lemonade after fixing the NVIDIA driver Hardware is detected once per server process, so a driver installed or updated while lemond runs is not seen until restart. Also say "not installed or not loaded", which covers a driver package whose kernel module failed to load. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LdWSB6ZjZctJ4yMjCV6nHm --------- Co-authored-by: Claude <[email protected]> |
||
|
|
204f00df74 |
feat(halogen): add the Halogen Flash container backend (#3712)
* feat(backends): run container backends through ContainerManager, starting with llamacpp:nathanw Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(containers): list every missing setup step and ask for consent at install Container setup now reports what a user still has to do in one pass, in the order they do it, and the CLI finishes the install once only consent is left. - Setup checks run in two groups. Before consent: the container tool on PATH, then the video/render groups (or the Docker socket), then enable_containers. These read only PATH, groups and sockets, so no container command runs before the user opts in; Podman counts as rootful when CONTAINER_HOST is set or lemond runs as root, until podman info answers. After consent: podman info, then SELinux. - Every failed check is reported at once. /system-info gives one problem per line in message, numbered steps in action (install commands, group changes, enable_containers, and logging out last), and the failed checks' ids in setup_checks. - lemonade backends prints message and action lines side by side. - lemonade backends install, run and load check the backend's setup before installing or downloading anything. When enable_containers is the only step left, they show the existing warning, enable it on yes and finish the command; backends install --yes skips the prompt. Otherwise they print every problem and step and exit 1. - The spec, user guide, CLI and API docs follow the new order and fields. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * fix(cli): read the selected backend only when recipe options were given lemonade run and load without a --<recipe> option have no recipe options, and reading the backend option from them aborted the CLI. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * style(containers): trim the setup comments the comment-slop hook flagged Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * ci(containers): gate the container smoke test like the other hosted test jobs The signing and release-branch skips exist to spare self-hosted runners; the smoke test runs on ubuntu-latest. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci(containers): pin the container smoke test to Ubuntu 24.04 The job installs the 24.04 .deb on the bare runner, and ubuntu-latest moves to 26.04 in November 2026, where libmbedcrypto7t64 does not exist. The comments now say why the job runs on the bare runner and needs the PPA. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): assert lemond's mode in the smoke test and log at debug test_03 now checks the published port on lemond's container, so each leg proves lemond detected the intended mode, not only that the tool runs in it. LEMONADE_CI_MODE puts llama-server's output in the uploaded logs, as in the other jobs that start lemond. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci: say why backends-gate also lists jobs that run on every PR Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(spec): cut the container spec changes back to what the implementation made false Keeps the opt-in invariants (off by default, install and load refused while off, no container command before opt-in), rootful Podman's connection path, the Podman answers check, and reporting every failed check at once. Drops setup_checks, action ordering, CLI prompting, and the expect_rootless detail. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(spec): name the enable warning instead of quoting it Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(llamacpp): list nathanw as a guest backend, as its descriptor declares Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(cli): word the enable_containers prompts as enabling containers, not backends The setting enables every container, whatever its tier, so the warning no longer calls the images community-built. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * chore(backends): drop the image allowlist comment from ContainerPolicy ContainerManager::allowed_image is the allowlist; the comment restated it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * refactor(containers): leave GPU selection and the SELinux check to the first ROCm container backend llamacpp:nathanw maps only /dev/dri, so nothing here reached the HIP_VISIBLE_DEVICES lookup or the SELinux check, both gated on /dev/kfd. needs_gfx1151_cwsr_fix goes back to its own KFD read. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): drop checks that restate code, and mount single files only The directory mounts serve Halogen's tokenizer and move to that PR; here every model file llamacpp names is a GGUF. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): take the smoke test's backend as --backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): leave Podman and Docker alone while enable_containers is false With containers disabled, lemond no longer sweeps at startup, connects to the Docker socket, runs `image inspect`, or removes images on uninstall. Setting enable_containers to false unloads every model running in a container first, so none is left that a later crash would orphan. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015BUXEd42tPQH67MQPW1XZh * Update to a modern pin * refactor(containers): drop the startup sweep A killed lemond's containers already stop and remove themselves: the attached `run --rm` child gets SIGTERM from PR_SET_PDEATHSIG and proxies it into the container. Verified with Docker and rootful/rootless Podman. The smoke test now kills lemond with a model loaded and checks no container remains. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * docs(load): list nathanw among the llamacpp_backend choices Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * ci(containers): cap the Dispatch container job at 45 minutes A hung job would otherwise hold a pool machine for up to 4 hours. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * test(containers): skip the killed-lemond check under rootful Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * docs(containers): link container images to their registry pages Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): skip the killed-lemond check under rootful Docker too The Docker daemon owns the container, so whether it stops after lemond is killed depends on the docker client forwarding SIGTERM in time, which is racy. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01R5SJqLuAuPwGaJQvWTwMai * refactor(containers): drop the enable_containers setting Container backends no longer need an opt-in before they install or load. The setup assistant's remaining checks still report what is missing. - Remove the config key, its validation, getter and config effect. - Remove the CLI consent prompt and pre-flight check, and the --yes flags on `config set` and `backends install` that only served it. - Always check the Docker socket, read the image on disk for installed state, and remove the image on uninstall. - Remove helpers left unused: containers_enabled, Router::get_container_model_names, WrappedServer::runs_in_container, ServerProcess::in_container. - Update the spec, guides, generated API docs, tests and CI. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * perf(containers): run container setup checks once per system-info build The checks are host-wide, so every container backend got the same report while each one ran them again, `podman info` included. Drop the unused recipe and backend parameters from container_setup_failure and compute its report at most once per pass. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * test(containers): fail when listing labeled containers or networks fails A failed `ps` or `network ls` printed nothing, so the checks that expect no leftovers passed without listing anything. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * feat(containers): run container backends from lemond.service with rootless Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): create Podman networks without a DNS server Every model load failed under lemond.service with Podman 5 (Fedora 43/44, Ubuntu 26.04, Debian 13): netavark: error while applying dns entries: aardvark-dns failed to start: Failed to connect to user scope bus via local transport `podman network create` turns DNS on by default, and rootless netavark (1.14 and later) starts aardvark-dns with `systemd-run --scope --user`, which needs the account's systemd user manager. The lemonade system account has no login session, so it has none. Each per-model network holds one container, and lemond reaches it through its published port or inspected address, never by name, so the network needs no DNS server. Docker has no such option and is unaffected. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(lemond.service): let rootless Podman keep its runtime state in the host's /tmp Every model load failed under lemond.service on Ubuntu 26.04 and Debian 13: Error: setting up Pasta: pasta failed with exit code 1: Couldn't open PID file /run/lemonade/containers/networks/rootless-netns/rootless-netns-conn.pid: Permission denied Podman 5 sets up rootless networking with pasta, under $XDG_RUNTIME_DIR, which the unit set to /run/lemonade. The AppArmor profile Ubuntu and Debian ship for pasta allows writes only under /tmp, /run/user/<uid> and home directories under /home, so it denied the PID file. ProtectHome=yes hides /run/user, and the account has no login session to create /run/user/<uid> in any case. With XDG_RUNTIME_DIR unset, Podman uses its own fallback in /tmp (/tmp/storage-run-<uid>, or /tmp/containers-user-<uid> on Podman 4), which the profile allows and Podman's own tmpfiles.d exempts from age-based cleanup. lemond's own runtime directory stays /run/lemonade, through RuntimeDirectory=. PrivateTmp goes with it. In a private /tmp, `podman` run as lemonade from a shell finds no runtime state, and Podman 5 then refreshes the shared database: the running container drops out of lemond's view, `podman stop` reports no such container, and the engine keeps holding the GPU until the service stops. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(debian): create /var/lib/cni at install On Ubuntu 24.04, every model load under lemond.service failed until the host next rebooted: Error: unable to find network with name or ID lemonade-<...>: network not found Podman 4's rootless network namespace bind-mounts a private directory over /var/lib/cni, or, while that does not exist, over its nearest existing parent, /var/lib. That mount hid /var/lib/lemonade, the lemonade account's home, which holds its Podman storage and network configs, so `podman run` found no network that `podman network create` had just made. Podman's own tmpfiles.d creates /var/lib/cni only at boot (`D!`), so a fresh install hit this until a reboot. The package now ships the directory in tmpfiles.d, which dh_installtmpfiles applies at install. The .rpm keeps lemonade's home in /opt, and Podman 5 makes no such mount, so neither needs it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): keep DNS on rootful Podman's per-model networks Podman 4's CNI backend gives an --internal network created with --disable-dns no gateway, so the host has no route to the container and rootful lemond, which connects at the container's address, waited on llama-server until the test timed out. Only rootless Podman needs DNS off, and it reaches the container through a published port. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(ds4): move ds4:rocm to a container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(containers): pick the ROCm container's GPU and check SELinux for /dev/kfd backends ds4:rocm is the first container backend that maps /dev/kfd. Its container gets HIP_VISIBLE_DEVICES for the GPU lemond sized it for, read from the KFD topology next to system_info's other KFD reads, and hosts with SELinux enforcing must allow containers to map GPU devices. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci(containers): restore the Dispatch container job's 4-hour timeout Four ds4 jobs downloading DS4's 81 GB checkpoint at once on fresh Dispatch machines each ran past 45 minutes. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(containers): run container backends from lemond.service with rootless Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): create Podman networks without a DNS server Every model load failed under lemond.service with Podman 5 (Fedora 43/44, Ubuntu 26.04, Debian 13): netavark: error while applying dns entries: aardvark-dns failed to start: Failed to connect to user scope bus via local transport `podman network create` turns DNS on by default, and rootless netavark (1.14 and later) starts aardvark-dns with `systemd-run --scope --user`, which needs the account's systemd user manager. The lemonade system account has no login session, so it has none. Each per-model network holds one container, and lemond reaches it through its published port or inspected address, never by name, so the network needs no DNS server. Docker has no such option and is unaffected. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(lemond.service): let rootless Podman keep its runtime state in the host's /tmp Every model load failed under lemond.service on Ubuntu 26.04 and Debian 13: Error: setting up Pasta: pasta failed with exit code 1: Couldn't open PID file /run/lemonade/containers/networks/rootless-netns/rootless-netns-conn.pid: Permission denied Podman 5 sets up rootless networking with pasta, under $XDG_RUNTIME_DIR, which the unit set to /run/lemonade. The AppArmor profile Ubuntu and Debian ship for pasta allows writes only under /tmp, /run/user/<uid> and home directories under /home, so it denied the PID file. ProtectHome=yes hides /run/user, and the account has no login session to create /run/user/<uid> in any case. With XDG_RUNTIME_DIR unset, Podman uses its own fallback in /tmp (/tmp/storage-run-<uid>, or /tmp/containers-user-<uid> on Podman 4), which the profile allows and Podman's own tmpfiles.d exempts from age-based cleanup. lemond's own runtime directory stays /run/lemonade, through RuntimeDirectory=. PrivateTmp goes with it. In a private /tmp, `podman` run as lemonade from a shell finds no runtime state, and Podman 5 then refreshes the shared database: the running container drops out of lemond's view, `podman stop` reports no such container, and the engine keeps holding the GPU until the service stops. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(halogen): add the Halogen Flash container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(debian): create /var/lib/cni at install On Ubuntu 24.04, every model load under lemond.service failed until the host next rebooted: Error: unable to find network with name or ID lemonade-<...>: network not found Podman 4's rootless network namespace bind-mounts a private directory over /var/lib/cni, or, while that does not exist, over its nearest existing parent, /var/lib. That mount hid /var/lib/lemonade, the lemonade account's home, which holds its Podman storage and network configs, so `podman run` found no network that `podman network create` had just made. Podman's own tmpfiles.d creates /var/lib/cni only at boot (`D!`), so a fresh install hit this until a reboot. The package now ships the directory in tmpfiles.d, which dh_installtmpfiles applies at install. The .rpm keeps lemonade's home in /opt, and Podman 5 makes no such mount, so neither needs it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(ds4): move ds4:rocm to a container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(halogen): read the gfx1151 KFD node through system_info and report the setup steps Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(rocmfpx): add the ROCm FPX container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): keep DNS on rootful Podman's per-model networks Podman 4's CNI backend gives an --internal network created with --disable-dns no gateway, so the host has no route to the container and rootful lemond, which connects at the container's address, waited on llama-server until the test timed out. Only rootless Podman needs DNS off, and it reaches the container through a published port. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(containers): pick the ROCm container's GPU and check SELinux for /dev/kfd backends ds4:rocm is the first container backend that maps /dev/kfd. Its container gets HIP_VISIBLE_DEVICES for the GPU lemond sized it for, read from the KFD topology next to system_info's other KFD reads, and hosts with SELinux enforcing must allow containers to map GPU devices. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(containers): mount a model directory one file at a time, for Halogen's tokenizer Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(api): regenerate for the rocmfpx section Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * fix(app): show container setup steps in a collapsible section The Setup guide button passed `action` to window.open, but lemond's `action` holds a command, steps, or a link. A non-link action now shows as a "Setup required" disclosure with the failure message and steps, regardless of the technical-details toggle; links keep the button. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): check GPU device access instead of video/render membership Desktop distros such as Ubuntu and Arch grant the logged-in account /dev/kfd and /dev/dri access through ACLs, so an account outside video and render could use the GPU yet was told to fix its groups. The setup check now tests read/write access to /dev/kfd and each render node. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): ask Podman its mode before the host check container_setup_failure() ran check_host() before check_podman(), so the first pass after startup guessed rootless and could report a GPU access failure on rootful Podman that the next pass cleared. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): check Docker with docker info instead of a fixed socket The socket probe only looked at /var/run/docker.sock, so DOCKER_HOST, Docker contexts and Docker Desktop's socket read as a refused account. docker info follows the CLI's own connection, and its answer also identifies Docker Desktop and rootless Docker, which cannot run container backends, so those now get Podman as the fix step. The spec's device-node rows now describe the access check instead of group membership. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(lemond.service): keep PrivateTmp and give Podman's private /tmp state to tmpfiles.d |
||
|
|
07af4f36b1 |
feat(ds4): move ds4:rocm to a container backend (#3710)
* feat(backends): run container backends through ContainerManager, starting with llamacpp:nathanw Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(containers): list every missing setup step and ask for consent at install Container setup now reports what a user still has to do in one pass, in the order they do it, and the CLI finishes the install once only consent is left. - Setup checks run in two groups. Before consent: the container tool on PATH, then the video/render groups (or the Docker socket), then enable_containers. These read only PATH, groups and sockets, so no container command runs before the user opts in; Podman counts as rootful when CONTAINER_HOST is set or lemond runs as root, until podman info answers. After consent: podman info, then SELinux. - Every failed check is reported at once. /system-info gives one problem per line in message, numbered steps in action (install commands, group changes, enable_containers, and logging out last), and the failed checks' ids in setup_checks. - lemonade backends prints message and action lines side by side. - lemonade backends install, run and load check the backend's setup before installing or downloading anything. When enable_containers is the only step left, they show the existing warning, enable it on yes and finish the command; backends install --yes skips the prompt. Otherwise they print every problem and step and exit 1. - The spec, user guide, CLI and API docs follow the new order and fields. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * fix(cli): read the selected backend only when recipe options were given lemonade run and load without a --<recipe> option have no recipe options, and reading the backend option from them aborted the CLI. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * style(containers): trim the setup comments the comment-slop hook flagged Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01V3HB9nm64VVxScERksHiia * ci(containers): gate the container smoke test like the other hosted test jobs The signing and release-branch skips exist to spare self-hosted runners; the smoke test runs on ubuntu-latest. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci(containers): pin the container smoke test to Ubuntu 24.04 The job installs the 24.04 .deb on the bare runner, and ubuntu-latest moves to 26.04 in November 2026, where libmbedcrypto7t64 does not exist. The comments now say why the job runs on the bare runner and needs the PPA. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): assert lemond's mode in the smoke test and log at debug test_03 now checks the published port on lemond's container, so each leg proves lemond detected the intended mode, not only that the tool runs in it. LEMONADE_CI_MODE puts llama-server's output in the uploaded logs, as in the other jobs that start lemond. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci: say why backends-gate also lists jobs that run on every PR Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(spec): cut the container spec changes back to what the implementation made false Keeps the opt-in invariants (off by default, install and load refused while off, no container command before opt-in), rootful Podman's connection path, the Podman answers check, and reporting every failed check at once. Drops setup_checks, action ordering, CLI prompting, and the expect_rootless detail. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(spec): name the enable warning instead of quoting it Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * docs(llamacpp): list nathanw as a guest backend, as its descriptor declares Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(cli): word the enable_containers prompts as enabling containers, not backends The setting enables every container, whatever its tier, so the warning no longer calls the images community-built. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * chore(backends): drop the image allowlist comment from ContainerPolicy ContainerManager::allowed_image is the allowlist; the comment restated it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * refactor(containers): leave GPU selection and the SELinux check to the first ROCm container backend llamacpp:nathanw maps only /dev/dri, so nothing here reached the HIP_VISIBLE_DEVICES lookup or the SELinux check, both gated on /dev/kfd. needs_gfx1151_cwsr_fix goes back to its own KFD read. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): drop checks that restate code, and mount single files only The directory mounts serve Halogen's tokenizer and move to that PR; here every model file llamacpp names is a GGUF. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): take the smoke test's backend as --backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): leave Podman and Docker alone while enable_containers is false With containers disabled, lemond no longer sweeps at startup, connects to the Docker socket, runs `image inspect`, or removes images on uninstall. Setting enable_containers to false unloads every model running in a container first, so none is left that a later crash would orphan. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015BUXEd42tPQH67MQPW1XZh * Update to a modern pin * refactor(containers): drop the startup sweep A killed lemond's containers already stop and remove themselves: the attached `run --rm` child gets SIGTERM from PR_SET_PDEATHSIG and proxies it into the container. Verified with Docker and rootful/rootless Podman. The smoke test now kills lemond with a model loaded and checks no container remains. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * docs(load): list nathanw among the llamacpp_backend choices Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * ci(containers): cap the Dispatch container job at 45 minutes A hung job would otherwise hold a pool machine for up to 4 hours. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * test(containers): skip the killed-lemond check under rootful Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LcAshvLHhLPAw6Ka6CJXwC * docs(containers): link container images to their registry pages Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * test(containers): skip the killed-lemond check under rootful Docker too The Docker daemon owns the container, so whether it stops after lemond is killed depends on the docker client forwarding SIGTERM in time, which is racy. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01R5SJqLuAuPwGaJQvWTwMai * refactor(containers): drop the enable_containers setting Container backends no longer need an opt-in before they install or load. The setup assistant's remaining checks still report what is missing. - Remove the config key, its validation, getter and config effect. - Remove the CLI consent prompt and pre-flight check, and the --yes flags on `config set` and `backends install` that only served it. - Always check the Docker socket, read the image on disk for installed state, and remove the image on uninstall. - Remove helpers left unused: containers_enabled, Router::get_container_model_names, WrappedServer::runs_in_container, ServerProcess::in_container. - Update the spec, guides, generated API docs, tests and CI. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * perf(containers): run container setup checks once per system-info build The checks are host-wide, so every container backend got the same report while each one ran them again, `podman info` included. Drop the unused recipe and backend parameters from container_setup_failure and compute its report at most once per pass. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * test(containers): fail when listing labeled containers or networks fails A failed `ps` or `network ls` printed nothing, so the checks that expect no leftovers passed without listing anything. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019cGBZamSKYLVeygD6axiu9 * feat(containers): run container backends from lemond.service with rootless Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): create Podman networks without a DNS server Every model load failed under lemond.service with Podman 5 (Fedora 43/44, Ubuntu 26.04, Debian 13): netavark: error while applying dns entries: aardvark-dns failed to start: Failed to connect to user scope bus via local transport `podman network create` turns DNS on by default, and rootless netavark (1.14 and later) starts aardvark-dns with `systemd-run --scope --user`, which needs the account's systemd user manager. The lemonade system account has no login session, so it has none. Each per-model network holds one container, and lemond reaches it through its published port or inspected address, never by name, so the network needs no DNS server. Docker has no such option and is unaffected. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(lemond.service): let rootless Podman keep its runtime state in the host's /tmp Every model load failed under lemond.service on Ubuntu 26.04 and Debian 13: Error: setting up Pasta: pasta failed with exit code 1: Couldn't open PID file /run/lemonade/containers/networks/rootless-netns/rootless-netns-conn.pid: Permission denied Podman 5 sets up rootless networking with pasta, under $XDG_RUNTIME_DIR, which the unit set to /run/lemonade. The AppArmor profile Ubuntu and Debian ship for pasta allows writes only under /tmp, /run/user/<uid> and home directories under /home, so it denied the PID file. ProtectHome=yes hides /run/user, and the account has no login session to create /run/user/<uid> in any case. With XDG_RUNTIME_DIR unset, Podman uses its own fallback in /tmp (/tmp/storage-run-<uid>, or /tmp/containers-user-<uid> on Podman 4), which the profile allows and Podman's own tmpfiles.d exempts from age-based cleanup. lemond's own runtime directory stays /run/lemonade, through RuntimeDirectory=. PrivateTmp goes with it. In a private /tmp, `podman` run as lemonade from a shell finds no runtime state, and Podman 5 then refreshes the shared database: the running container drops out of lemond's view, `podman stop` reports no such container, and the engine keeps holding the GPU until the service stops. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(debian): create /var/lib/cni at install On Ubuntu 24.04, every model load under lemond.service failed until the host next rebooted: Error: unable to find network with name or ID lemonade-<...>: network not found Podman 4's rootless network namespace bind-mounts a private directory over /var/lib/cni, or, while that does not exist, over its nearest existing parent, /var/lib. That mount hid /var/lib/lemonade, the lemonade account's home, which holds its Podman storage and network configs, so `podman run` found no network that `podman network create` had just made. Podman's own tmpfiles.d creates /var/lib/cni only at boot (`D!`), so a fresh install hit this until a reboot. The package now ships the directory in tmpfiles.d, which dh_installtmpfiles applies at install. The .rpm keeps lemonade's home in /opt, and Podman 5 makes no such mount, so neither needs it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): keep DNS on rootful Podman's per-model networks Podman 4's CNI backend gives an --internal network created with --disable-dns no gateway, so the host has no route to the container and rootful lemond, which connects at the container's address, waited on llama-server until the test timed out. Only rootless Podman needs DNS off, and it reaches the container through a published port. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(ds4): move ds4:rocm to a container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(containers): pick the ROCm container's GPU and check SELinux for /dev/kfd backends ds4:rocm is the first container backend that maps /dev/kfd. Its container gets HIP_VISIBLE_DEVICES for the GPU lemond sized it for, read from the KFD topology next to system_info's other KFD reads, and hosts with SELinux enforcing must allow containers to map GPU devices. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * ci(containers): restore the Dispatch container job's 4-hour timeout Four ds4 jobs downloading DS4's 81 GB checkpoint at once on fresh Dispatch machines each ran past 45 minutes. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(containers): run container backends from lemond.service with rootless Podman Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): create Podman networks without a DNS server Every model load failed under lemond.service with Podman 5 (Fedora 43/44, Ubuntu 26.04, Debian 13): netavark: error while applying dns entries: aardvark-dns failed to start: Failed to connect to user scope bus via local transport `podman network create` turns DNS on by default, and rootless netavark (1.14 and later) starts aardvark-dns with `systemd-run --scope --user`, which needs the account's systemd user manager. The lemonade system account has no login session, so it has none. Each per-model network holds one container, and lemond reaches it through its published port or inspected address, never by name, so the network needs no DNS server. Docker has no such option and is unaffected. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(lemond.service): let rootless Podman keep its runtime state in the host's /tmp Every model load failed under lemond.service on Ubuntu 26.04 and Debian 13: Error: setting up Pasta: pasta failed with exit code 1: Couldn't open PID file /run/lemonade/containers/networks/rootless-netns/rootless-netns-conn.pid: Permission denied Podman 5 sets up rootless networking with pasta, under $XDG_RUNTIME_DIR, which the unit set to /run/lemonade. The AppArmor profile Ubuntu and Debian ship for pasta allows writes only under /tmp, /run/user/<uid> and home directories under /home, so it denied the PID file. ProtectHome=yes hides /run/user, and the account has no login session to create /run/user/<uid> in any case. With XDG_RUNTIME_DIR unset, Podman uses its own fallback in /tmp (/tmp/storage-run-<uid>, or /tmp/containers-user-<uid> on Podman 4), which the profile allows and Podman's own tmpfiles.d exempts from age-based cleanup. lemond's own runtime directory stays /run/lemonade, through RuntimeDirectory=. PrivateTmp goes with it. In a private /tmp, `podman` run as lemonade from a shell finds no runtime state, and Podman 5 then refreshes the shared database: the running container drops out of lemond's view, `podman stop` reports no such container, and the engine keeps holding the GPU until the service stops. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(debian): create /var/lib/cni at install On Ubuntu 24.04, every model load under lemond.service failed until the host next rebooted: Error: unable to find network with name or ID lemonade-<...>: network not found Podman 4's rootless network namespace bind-mounts a private directory over /var/lib/cni, or, while that does not exist, over its nearest existing parent, /var/lib. That mount hid /var/lib/lemonade, the lemonade account's home, which holds its Podman storage and network configs, so `podman run` found no network that `podman network create` had just made. Podman's own tmpfiles.d creates /var/lib/cni only at boot (`D!`), so a fresh install hit this until a reboot. The package now ships the directory in tmpfiles.d, which dh_installtmpfiles applies at install. The .rpm keeps lemonade's home in /opt, and Podman 5 makes no such mount, so neither needs it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * feat(ds4): move ds4:rocm to a container backend Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(containers): keep DNS on rootful Podman's per-model networks Podman 4's CNI backend gives an --internal network created with --disable-dns no gateway, so the host has no route to the container and rootful lemond, which connects at the container's address, waited on llama-server until the test timed out. Only rootless Podman needs DNS off, and it reaches the container through a published port. Co-Authored-By: Claude Opus 5.5 <[email protected]> * feat(containers): pick the ROCm container's GPU and check SELinux for /dev/kfd backends ds4:rocm is the first container backend that maps /dev/kfd. Its container gets HIP_VISIBLE_DEVICES for the GPU lemond sized it for, read from the KFD topology next to system_info's other KFD reads, and hosts with SELinux enforcing must allow containers to map GPU devices. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> * fix(app): show container setup steps in a collapsible section The Setup guide button passed `action` to window.open, but lemond's `action` holds a command, steps, or a link. A non-link action now shows as a "Setup required" disclosure with the failure message and steps, regardless of the technical-details toggle; links keep the button. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): check GPU device access instead of video/render membership Desktop distros such as Ubuntu and Arch grant the logged-in account /dev/kfd and /dev/dri access through ACLs, so an account outside video and render could use the GPU yet was told to fix its groups. The setup check now tests read/write access to /dev/kfd and each render node. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): ask Podman its mode before the host check container_setup_failure() ran check_host() before check_podman(), so the first pass after startup guessed rootless and could report a GPU access failure on rootful Podman that the next pass cleared. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(containers): check Docker with docker info instead of a fixed socket The socket probe only looked at /var/run/docker.sock, so DOCKER_HOST, Docker contexts and Docker Desktop's socket read as a refused account. docker info follows the CLI's own connection, and its answer also identifies Docker Desktop and rootless Docker, which cannot run container backends, so those now get Podman as the fix step. The spec's device-node rows now describe the access check instead of group membership. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(lemond.service): keep PrivateTmp and give Podman's private /tmp state to tmpfiles.d |
||
|
|
25990159a0 |
fix(server): report NVIDIA GPU and VRAM usage (#3282)
* fix(server): report NVIDIA GPU and VRAM usage * fix(server): address NVIDIA metrics review feedback * adapt static options nvidia_metrics.h * refactor and consider multi gpu * add metric c++unit test * adreess review * fix(server): address NVIDIA metrics follow-up review * refactor the multi GPU handling * fix(server): library detection |
||
|
|
6d0e01f505 |
Report the AMD GPU marketing name on Linux (#3601)
The Linux KFD path put gfx_target_version in GPUInfo::name because the ROCm arch lookup reads that field, so system-info reported the card as "120001". Keep name as the ISA for the arch lookup and carry a display name alongside it, built from libdrm's marketing name, then prefer it in the device JSON. The HSA path already composed a display name the same way, so that logic moves to a shared gpu_display_name() helper and both paths call it. A GPU with no marketing name, or with an unrecognized gfx_target_version, keeps reporting what it reported before. Covered by SystemInfoHelpersTest; the Windows and macOS paths are untouched. |
||
|
|
61c4e49143 |
fix(vllm): scale gpu-memory-utilization to free memory on shared-memory devices (#3344)
* fix(vllm): scale gpu-memory-utilization to free memory on shared-memory devices vLLM refuses to start unless gpu_memory_utilization of the total pool is free, a pre-flight check the --kv-cache-memory-bytes cap does not relax. On shared-memory devices any co-tenant process holding more than ~2.5 GiB rejects models that fit comfortably. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> * fix(vllm): size the startup memory demand from the target GPU The scaled --gpu-memory-utilization was derived from get_global_vram_usage_pct(), which folds every GPU in the machine into one worst-case ratio and falls back to the dedicated VRAM carve-out when its libdrm probe cannot open a render node. Both make the reading describe a device vLLM may never touch, so an unrelated busy GPU -- or a service account outside the `render` group -- could clamp the request low enough to fail a load that previously succeeded. Read the amdgpu driver's own per-device accounting for the GPU whose ISA the launch policy was derived from, via world-readable KFD topology and sysfs. The probe reports nothing unless exactly one GPU matches, so an ambiguous or unreadable topology leaves vLLM on its own default rather than on another device's numbers. The utilization now only steps in where vLLM's default would actually be rejected, truncates rather than rounds so it never asks for more than is free, and declines to emit a budget too small to hold the kv-cache cap beside it -- vLLM's own pre-flight names the byte counts in that case. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]> Co-authored-by: ramkrishna2910 <[email protected]> |
||
|
|
f33cca7ade | test: replace Python system info replicas with C++ coverage (#3020) |