Phase 0: fresh vllm 0.18.1 + mooncake-transfer-engine on dash1/dash2
Install script lives in microbench/fresh_setup/install.sh. Single shared venv at /home/admin/cpfs/wjh/agentic-kv-fresh/.venv (cpfs is mounted at the same path on dash0/1/2 so one install serves all three). vllm : 0.18.1 (official wheel) mooncake-transfer-engine: 0.3.11.post1 Smoke-tested on dash1 + dash2: imports succeed, kv_transfer module resolves. This venv is the vanilla reference for all subsequent microbench / PD-disagg experiments — not the dash0 patched build that carries the connector_tax fix. The script defines proxyOn inline (ipads 127.0.0.1:11235) so it works under non-interactive ssh (~/.bashrc proxyOn is interactive-only). Sets -eo pipefail (not -u) because venv activation references unset PS1-like vars under -u. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
75
microbench/fresh_setup/install.sh
Normal file
75
microbench/fresh_setup/install.sh
Normal file
@@ -0,0 +1,75 @@
|
||||
#!/usr/bin/env bash
|
||||
# Fresh-vllm + Mooncake install for microbench (Phase 0).
|
||||
#
|
||||
# Idempotent. Runs from any dash machine that mounts /home/admin/cpfs/wjh/.
|
||||
# Single venv at FRESH_ROOT/.venv is shared by all dash hosts (cpfs is mounted
|
||||
# at the same path on dash0/1/2).
|
||||
#
|
||||
# Usage on each host:
|
||||
# bash microbench/fresh_setup/install.sh
|
||||
|
||||
set -eo pipefail
|
||||
# Note: NOT -u; bashrc / venv activation reference unset vars (PS1, etc.).
|
||||
|
||||
FRESH_ROOT="/home/admin/cpfs/wjh/agentic-kv-fresh"
|
||||
VENV_DIR="${FRESH_ROOT}/.venv"
|
||||
VLLM_VERSION="0.18.1"
|
||||
|
||||
mkdir -p "${FRESH_ROOT}"
|
||||
cd "${FRESH_ROOT}"
|
||||
|
||||
# 1. uv venv (Python 3.12). Skip if already exists and is valid.
|
||||
if [[ ! -f "${VENV_DIR}/bin/python" ]]; then
|
||||
echo "[install] creating venv at ${VENV_DIR}"
|
||||
uv venv --python 3.12 "${VENV_DIR}"
|
||||
else
|
||||
echo "[install] venv exists at ${VENV_DIR}, reusing"
|
||||
fi
|
||||
|
||||
# 2. Set proxy + activate venv. Avoid sourcing bashrc directly (it has
|
||||
# interactive-only stuff); define proxyOn locally instead.
|
||||
proxyOn() {
|
||||
local p="http://ipads:ipads123@127.0.0.1:11235"
|
||||
export http_proxy="$p" https_proxy="$p" all_proxy="$p"
|
||||
echo "[install] proxy set: $p"
|
||||
}
|
||||
proxyOn
|
||||
|
||||
# shellcheck disable=SC1090
|
||||
source "${VENV_DIR}/bin/activate"
|
||||
|
||||
echo "[install] python: $(which python) ($(python --version))"
|
||||
|
||||
# 3. Install vllm wheel.
|
||||
if ! python -c "import vllm" 2>/dev/null; then
|
||||
echo "[install] installing vllm==${VLLM_VERSION}"
|
||||
uv pip install "vllm==${VLLM_VERSION}"
|
||||
else
|
||||
INSTALLED=$(python -c "import vllm; print(vllm.__version__)")
|
||||
echo "[install] vllm already installed: ${INSTALLED}"
|
||||
fi
|
||||
|
||||
# 4. Install Mooncake transfer engine (vllm's standard kv_connector backend).
|
||||
# vllm 0.18.x mooncake connector imports mooncake.engine; the upstream package
|
||||
# is `mooncake-transfer-engine`.
|
||||
if ! python -c "import mooncake" 2>/dev/null; then
|
||||
echo "[install] installing mooncake-transfer-engine"
|
||||
uv pip install mooncake-transfer-engine
|
||||
else
|
||||
echo "[install] mooncake already installed"
|
||||
fi
|
||||
|
||||
# 5. Common test deps.
|
||||
uv pip install httpx pytest numpy
|
||||
|
||||
# 6. Smoke-test imports.
|
||||
python - <<'PY'
|
||||
import vllm
|
||||
import mooncake
|
||||
print(f"[smoke] vllm = {vllm.__version__}")
|
||||
print(f"[smoke] mooncake = {getattr(mooncake, '__version__', 'unknown')}")
|
||||
import vllm.distributed.kv_transfer as kvt
|
||||
print(f"[smoke] kv_transfer = {kvt.__file__}")
|
||||
PY
|
||||
|
||||
echo "[install] DONE"
|
||||
Reference in New Issue
Block a user