The Critical Infrastructure Reset: Stopping an Auto-Started vLLM Service After a VM Crash
Message Overview
The subject message is a single bash command executed by the AI assistant in response to a catastrophic infrastructure failure:
ssh -o ConnectTimeout=10 root@10.1.230.174 'systemctl stop vllm-kimi-k25-int4.service && systemctl disable vllm-kimi-k25-int4.service && echo "Stopped and disabled vllm service"'
This message appears simple — a one-liner that stops a systemd service and prevents it from restarting. But beneath its brevity lies a critical moment in a complex ML engineering workflow: the recovery from a VM crash that threatened days of computation, and the deliberate decision to permanently disable an auto-started inference server that had seized control of eight expensive GPUs.
The Catastrophic Context
To understand why this message was written, we must first understand what led to it. The broader conversation (segments 25–30 of this opencode session) chronicles a sophisticated EAGLE-3 speculative decoding training pipeline for the Kimi-K2.5 language model. The team had been extracting hidden states from the target model — a process that involves running the large Kimi-K2.5 model on eight RTX PRO 6000 Blackwell GPUs, capturing internal representations for each training sample, and saving them to disk. At the time of the crash, extraction was approximately 49% complete, with 18,420 out of 37,312 samples processed. The process had been running steadily at 1.09 samples per second, with an estimated 4.8 hours remaining.
Then disaster struck. As the user explained in [msg 4192]: "I had to kill the VM because the ceph cluster below the VM ran out of space quite catastrophically. New 15TB Nvme disk was attached directly to the host, kpro6, and the /data volume was moved to it."
This is a significant infrastructure failure. A Ceph cluster — a distributed storage system — running out of space "catastrophically" means the underlying storage for the VM became corrupted or unresponsive. The recovery involved attaching a brand-new 15TB NVMe drive directly to the host machine (bypassing the Ceph layer entirely) and migrating the /data volume to it. This is a non-trivial operation that required manual intervention from the infrastructure team.
When the container came back up, the assistant's first task was to assess what survived the crash. The GPUs showed 75.8 GB of memory allocated each but 0% utilization — something had auto-started and loaded the model weights. A quick process check revealed the culprit: a systemd service called vllm-kimi-k25-int4.service was running vLLM's OpenAI-compatible API server with the Kimi-K2.5 INT4 quantized model, consuming all 8 GPUs.
Why This Message Was Written: The Reasoning and Motivation
The assistant's motivation for this message was straightforward but critical: free the GPUs for the extraction restart. The hidden state extraction pipeline requires the SGLang server (not vLLM) to be running with a special hidden state dumping patch. vLLM and SGLang are both inference engines, but they serve different purposes in this workflow. vLLM was used in earlier phases for general inference and response generation, while SGLang with the custom patch is specifically needed for capturing the auxiliary hidden states that the EAGLE-3 drafter training depends on.
There were three intertwined reasons for stopping and disabling this service:
- GPU Memory Conflict: The vLLM server was holding ~76 GB per GPU, leaving no room for the SGLang extraction server. With 8 GPUs and a large MoE model, memory is the most constrained resource. You cannot run two large model servers simultaneously on the same GPUs.
- Port Conflict: Both vLLM and SGLang typically bind to port 8000 or 30000 for their API endpoints. Even if memory could be partitioned, the port conflict would prevent both from running.
- Permanent Disablement: The service was configured to auto-start on boot (
systemctl enable). If the VM were to reboot again during the multi-day extraction process, vLLM would re-seize the GPUs, requiring another manual intervention. Disabling the service prevents this recurrence. The assistant's choice to use&&chaining —systemctl stop && systemctl disable && echo "Stopped and disabled"— shows deliberate design. Thestopcommand halts the currently running process. Thedisablecommand removes the symlinks that cause the service to start at boot. The echo provides a confirmation message that the entire chain succeeded. If either command failed, the chain would halt and the echo would not print, giving the assistant immediate feedback about failure.
The Decision-Making Process
The assistant's path to this command involved several sequential discoveries visible in the preceding messages:
- Discovery of GPU occupation ([msg 4194]): Running
nvidia-smirevealed all 8 GPUs had ~75.8 GB allocated but 0% utilization — a clear sign of a loaded model sitting idle. - Identification of the running process ([msg 4195]):
ps auxshowed vLLM running with the Kimi-K2.5 INT4 model, consuming all GPUs. - Finding the auto-start mechanism ([msg 4196]): Checking systemd services revealed
vllm-kimi-k25-int4.serviceas the culprit. The assistant also checked crontab and listed all vLLM/SGLang-related systemd units, discovering a whole ecosystem of pre-existing service files. The key decision was: stop and disable, not just stop. A simplesystemctl stopwould free the GPUs immediately, but the service would restart on the next reboot. Given that the extraction process was expected to run for days (the original ETA was ~4.8 hours, but the full training pipeline would take much longer), preventing future auto-starts was essential. The assistant also chose not to mask the service (which creates a stronger block by symlinking to/dev/null), only to disable it — suggesting an assumption that the service might be needed again in the future and should remain available for manual start.
Assumptions Made
This message rests on several assumptions, some explicit and some implicit:
- That stopping vLLM is safe: The assistant assumes no other user or process depends on the vLLM API server. Given that the machine is a dedicated development server and the user explicitly asked to restart extraction, this is reasonable.
- That systemd is the correct management layer: The assistant assumes the service was properly registered with systemd and that
systemctl stopwill cleanly terminate the process. This is standard practice on Ubuntu 24.04. - That the service should be permanently disabled: The assistant assumes the vLLM service should not auto-start in the future. This is a judgment call — perhaps the user wanted vLLM to auto-start for production serving. But given the current workflow priority (EAGLE-3 training), disabling it is the right call.
- That SSH connectivity is stable: The
-o ConnectTimeout=10flag shows awareness that SSH connections to this machine can be slow or unreliable. The previous message ([msg 4195]) used the same timeout. - That the service name is correct: The assistant identified
vllm-kimi-k25-int4.servicefrom the systemd listing and used it without verification that this is the exact unit name. A typo here would cause the command to fail silently (the chain would stop at the first failure).
Mistakes and Incorrect Assumptions
The most notable issue with this message is that the command timed out. The bash metadata shows:
<bash_metadata>
bash tool terminated command after exceeding timeout 15000 ms
</bash_metadata>
The 15-second timeout was exceeded, meaning we never got confirmation that the service was successfully stopped and disabled. This could be due to:
- Slow SSH connection: The machine's SSH daemon might be slow to respond after the reboot and disk migration.
- systemd hanging:
systemctl stopsends a SIGTERM to the process, but if vLLM doesn't respond quickly, systemd waits for the timeout before sending SIGKILL. The defaultTimeoutStopSecis 90 seconds for many services, which would easily exceed the 15-second SSH timeout. - Network issues: The new NVMe disk is attached to host
kpro6, and the network path might have changed. The assistant did not retry or verify the command succeeded in the same message. In a synchronous tool-calling environment, the assistant must wait for the next round to check results. This creates a blind spot — the next message would need to verify that the GPUs were actually freed. A secondary issue is that the assistant did not check whether the vLLM service had any dependent services or whether stopping it would cascade to other processes. The earlier systemd listing ([msg 4196]) showed multiple vLLM-related services (vllm-glm5.service,vllm-kimi-k25-int4-ngram.service, etc.), suggesting a complex service dependency graph that might be affected.
Input Knowledge Required
To understand this message, the reader needs:
- Systemd fundamentals: Understanding that
systemctl stophalts a running service andsystemctl disableremoves its auto-start configuration. The&&operator chains commands so the next runs only if the previous succeeded. - The vLLM/SGLang ecosystem: vLLM is a popular LLM inference engine, and the Kimi-K2.5 INT4 model is a quantized 1-trillion-parameter MoE model that requires multiple GPUs to run. The service name encodes the model variant.
- GPU memory constraints in ML: Large language models consume VRAM proportional to their parameter count. An 8-GPU setup with ~96 GB per GPU is barely enough for a 1T MoE model, meaning every megabyte counts.
- The crash recovery context: The Ceph failure and disk migration explain why the container rebooted and why the extraction must be restarted from a checkpoint rather than continuing seamlessly.
- SSH and remote execution patterns: The
-o ConnectTimeout=10flag and the timeout metadata indicate the reliability challenges of managing remote infrastructure.
Output Knowledge Created
This message produces several concrete outcomes:
- Immediate: The vLLM process receives a SIGTERM signal and begins shutting down. GPU memory is gradually released as the model is unloaded.
- Boot-time: The systemd symlinks for
vllm-kimi-k25-int4.serviceare removed from the multi-user.target.wants directory, preventing future auto-starts. - Verification signal: If the chain completes, the echo statement prints confirmation. If it fails, the assistant knows something went wrong.
- Documentation in the conversation: The command and its outcome (or lack thereof) are recorded, creating an audit trail for the infrastructure changes made.
The Thinking Process
The assistant's reasoning, visible across the preceding messages, follows a clear investigative pattern:
- Observe symptoms: GPUs show memory allocation but zero utilization — something is loaded but idle.
- Identify the process:
ps auxreveals vLLM running with the Kimi-K2.5 INT4 model. - Trace the cause: Check systemd services and crontab to find the auto-start mechanism.
- Assess the environment: Discover multiple vLLM-related service files, suggesting a history of different model deployments.
- Formulate the fix: Stop the running service to free GPUs, disable it to prevent recurrence, and use chained commands with confirmation output for reliable execution.
- Execute: Issue the SSH command with a 10-second connect timeout, acknowledging the network reliability issues. The assistant did not consider alternatives like: - Killing the process with
killorpkill(which would not prevent auto-start) - Masking the service (stronger block than disable) - Modifying the service file to change its behavior - Leaving vLLM running and running SGLang on a subset of GPUs The chosen approach is pragmatic and minimal: do the minimum necessary to clear the path for extraction, with an emphasis on preventing the same problem from recurring.
Broader Significance
This message represents a classic infrastructure management pattern in ML engineering: the conflict between persistent serving infrastructure and ad-hoc research workflows. The vLLM service was presumably set up earlier in the conversation (or by a previous engineer) to serve the Kimi-K2.5 model as a production API endpoint. But the current research workflow — EAGLE-3 training — requires the GPUs for a different purpose. The systemd service embodies the tension between "this machine serves a model" and "this machine trains a model."
The assistant's decision to disable the service (rather than just stop it) is a declaration that the training workflow takes priority. It's a small but meaningful infrastructure governance decision: when the VM reboots next, it will not automatically load the model, giving the research workflow a clean slate.
This message also illustrates the fragility of long-running ML pipelines. Days of hidden state extraction were interrupted by a storage failure. The recovery involves not just restarting the extraction script but also clearing the infrastructure debris — auto-started services, stale processes, and changed disk paths — that accumulated during normal operation. Each of these small interventions (stopping vLLM, killing stale processes, verifying disk integrity) is individually simple, but together they form the critical path to recovery.