Commands for the recovery library described in Oracles, Traces, Triage. Updated October 24, 2026.
These commands assume that my archived LLM/ library is already present
on the named SSD. The kit scripts and payloads are not distributed with
this blog. This page records their interfaces; it is not a complete
installer for a reader who has only downloaded the page.
Use the profile matching the physical machine. Changing the SSD’s mount name does not change the target profile. M3 Ultra 256 GB and M5 Max 128 GB are the accepted targets. A VM and the reserved M5 Ultra profile are not qualified. Run one inference engine at a time.
Run plan first. If it succeeds, run restore interactively and handle
administrator and Apple-license prompts yourself.
bash "/Volumes/VMStore-m3/LLM/restore-all.sh" plan m3-ultra-256gb
bash "/Volumes/VMStore-m3/LLM/restore-all.sh" restore m3-ultra-256gb
This installs four DwarfStar and five Orca profiles. It leaves persistent servers stopped and does not add firewall exceptions.
Use these instead of the all-model restore. Run the manager copy only after the single-model restore succeeds.
KIT="/Volumes/VMStore-m3/LLM/machines/m3-ultra-256gb/DwarfStar"
# Restore DeepSeek V4 Flash 0731.
zsh "$KIT/single-model-kit-v1/restore-ds4-downloads-layout.zsh" restore
# Install its local manager.
cp -p "$KIT/single-model-kit-v1/restore-ds4-downloads-layout.zsh" \
"$HOME/Downloads/DwarfStar/m3-ultra-256gb-single-model-kit-v1/manage.zsh"
# Restore DeepSeek V4.1 Flash 1017, GLM, and Qwen, including their manager.
zsh "$KIT/three-models-kit-v1/restore.zsh" all
Define the directories in the current Terminal:
SINGLE="$HOME/Downloads/DwarfStar/m3-ultra-256gb-single-model-kit-v1"
THREE="$HOME/Downloads/DwarfStar/m3-ultra-256gb-three-models-kit-v1"
ORCA="$HOME/Downloads/Orca/m3-ultra-256gb-five-models-kit-v1"
| Model | Directory | Model argument | Context cap |
|---|---|---|---|
| DeepSeek V4 Flash 0731 | $SINGLE |
Omit | 200,000 |
| DeepSeek V4.1 Flash 1017 | $THREE |
deepseek |
200,000 |
| GLM 5.3 Flash | $THREE |
glm |
200,000 |
| Qwen3.8 Flash Next | $THREE |
qwen |
200,000 |
| Orca Qwen3.8 27B | $ORCA |
qwen |
131,072 |
| Orca Nex-N2.5-mini | $ORCA |
nex |
131,072 |
| OrcaSAQ-2 Cyber 27B | $ORCA |
orcasaq |
131,072 |
| Orca GLM 5.3 Flash | $ORCA |
glm |
131,072 |
| Orca DeepSeek V4 Flash | $ORCA |
deepseek |
131,072 |
The older M3 0731 manager takes an action directly and has no probe
subcommand. Do not insert a model key:
zsh "$SINGLE/manage.zsh" start
zsh "$SINGLE/manage.zsh" status
zsh "$SINGLE/manage.zsh" stop
For the other models, choose the directory and key from the table, then run the lifecycle commands individually. This example selects the newer DwarfStar DeepSeek:
MANAGER="$THREE/manage.zsh"
MODEL=deepseek
zsh "$MANAGER" "$MODEL" start
zsh "$MANAGER" "$MODEL" status
zsh "$MANAGER" "$MODEL" probe
zsh "$MANAGER" "$MODEL" stop
Run after restoration. For a DwarfStar-only installation, remove the two
"$o/..." entries. This preserves the firewall’s enabled/disabled state
and starts no model. Exceptions apply to applications, not just the model
ports or one source IP. The servers do not provide API authentication.
bash <<'FIREWALL'
set -euo pipefail
fw=/usr/libexec/ApplicationFirewall/socketfilterfw
d="$HOME/Downloads/DwarfStar"
o="$HOME/Downloads/Orca/m3-ultra-256gb-five-models-kit-v1"
apps=(
"$d/m3-ultra-256gb-single-model-kit-v1/source/ds4-server"
"$d/m3-ultra-256gb-three-models-kit-v1/source/ds4-server"
"$o/llama/llama-server"
"$o/python/bin/python3.12"
)
for app in "${apps[@]}"; do
if [ ! -x "$app" ]; then
echo "Missing executable: $app"
exit 1
fi
done
sudo -v
for app in "${apps[@]}"; do
sudo "$fw" --add "$app"
sudo "$fw" --unblockapp "$app"
"$fw" --getappblocked "$app"
done
"$fw" --getglobalstate
"$fw" --listapps
FIREWALL
cat "/Volumes/VMStore-m3/LLM/OPERATIONS.txt"
cat "$HOME/Downloads/recovery-setup/m3-ultra-256gb/OPERATIONS.txt"
Run plan first, then restore interactively. This installs four
DwarfStar and four Orca profiles. Orca DeepSeek is deliberately excluded.
bash "/Volumes/VMStore-m5/LLM/restore-all.sh" plan m5-max-128gb
bash "/Volumes/VMStore-m5/LLM/restore-all.sh" restore m5-max-128gb
The clean restore and eight sequential generation smoke tests passed. That installation does not need to be restored again to use these commands. Restore leaves persistent servers stopped and firewall setup separate.
SINGLE="$HOME/Downloads/DwarfStar/m5-max-128gb-single-model-kit-v1"
THREE="$HOME/Downloads/DwarfStar/m5-max-128gb-three-models-kit-v1"
ORCA="$HOME/Downloads/Orca/m5-max-128gb-four-models-kit-v1"
| Model | Directory | Model argument | Context cap |
|---|---|---|---|
| DeepSeek V4 Flash 0731 | $SINGLE |
deepseek |
200,000 |
| DeepSeek V4.1 Flash 1017 | $THREE |
deepseek |
200,000 |
| GLM 5.3 Flash | $THREE |
glm |
200,000 |
| Qwen3.8 Flash Next | $THREE |
qwen |
200,000 |
| Orca Qwen3.8 27B | $ORCA |
qwen |
131,072 |
| Orca Nex-N2.5-mini | $ORCA |
nex |
131,072 |
| OrcaSAQ-2 Cyber 27B | $ORCA |
orcasaq |
131,072 |
| Orca GLM 5.3 Flash | $ORCA |
glm |
131,072 |
Every M5 manager takes a model key, including the single-model manager. This example selects 0731. Run each action separately:
MANAGER="$SINGLE/manage.zsh"
MODEL=deepseek
zsh "$MANAGER" "$MODEL" start
zsh "$MANAGER" "$MODEL" status
zsh "$MANAGER" "$MODEL" probe
zsh "$MANAGER" "$MODEL" stop
The M5 has a separate Orca GLM native server, so there are five executable
paths. For a DwarfStar-only installation, omit all three "$o/..." entries.
The same application-wide scope and lack of API authentication apply.
bash <<'FIREWALL'
set -euo pipefail
fw=/usr/libexec/ApplicationFirewall/socketfilterfw
d="$HOME/Downloads/DwarfStar"
o="$HOME/Downloads/Orca/m5-max-128gb-four-models-kit-v1"
apps=(
"$d/m5-max-128gb-single-model-kit-v1/source/ds4-server"
"$d/m5-max-128gb-three-models-kit-v1/source/ds4-server"
"$o/llama/llama-server"
"$o/llama-glm/llama-server"
"$o/python/bin/python3.12"
)
for app in "${apps[@]}"; do
if [ ! -x "$app" ]; then
echo "Missing executable: $app"
exit 1
fi
done
sudo -v
for app in "${apps[@]}"; do
sudo "$fw" --add "$app"
sudo "$fw" --unblockapp "$app"
"$fw" --getappblocked "$app"
done
"$fw" --getglobalstate
"$fw" --listapps
FIREWALL
cat "/Volumes/VMStore-m5/LLM/machines/m5-max-128gb/OPERATIONS.txt"
cat "$HOME/Downloads/recovery-setup/m5-max-128gb/OPERATIONS.txt"
DwarfStar uses port 8000; Orca uses port 8100. Run this on the inference Mac while a DwarfStar model is running:
curl --connect-timeout 5 --max-time 15 http://127.0.0.1:8000/v1/models
A model listing establishes HTTP reachability, not successful generation.
For a LAN check, replace 127.0.0.1 with the inference Mac’s actual LAN
address and run from another machine. The 0731 API model ID is
deepseek-v4-flash; its API base is http://HOST:8000/v1.
Alternatively, with SSH already configured for the alias inference-mac:
ssh -N -o ExitOnForwardFailure=yes \
-L 127.0.0.1:18000:127.0.0.1:8000 inference-mac
Keep that tunnel open and use http://127.0.0.1:18000/v1 from the client.
A service bound only to loopback can be reached this way without allowing
direct LAN connections to its executable. SSH itself must be reachable.
After restoration and verification have finished, leave directories on the SSD and eject it. This example is for VMStore-m5; substitute VMStore-m3 when appropriate.
cd ~
diskutil eject "/Volumes/VMStore-m5"
if mount | grep -Fq ' on /Volumes/VMStore-m5 ('; then
echo "STILL MOUNTED - do not unplug"
else
echo "VMStore-m5 is not mounted"
fi
Wait for successful ejection and confirmation that the volume is no longer mounted. Do not force a busy disk. Installed models run from internal storage, including the M5 DeepSeek expert-streaming files.
The full library revision discussed here is 3b8e658. The two native DS4
engine pins are 0aaea5a238fb41a35106a551e73c8409dfb751ac for 0731 and
5379c1c9ac315f1540371b06a3db88491d4059ff for the three-model kits.