14 KiB
Two-host TP2 physical qualification runbook (E3/E4)
Use this runbook to collect physical LMS-E3 and LMS-E4 evidence for the rank-local candidate on rented hardware. The protocol itself is described in the two-host protocol note. This runbook does not grant authorization. A passing run does not change support status, and neither does a passing checker. Only a maintainer-reviewed registry record can do that.
0. Preconditions (blockers if missing)
- An exact signed candidate commit has been selected through the trusted manual workflow (conditional testing). This is the observation candidate. Section 2 replaces it with the final candidate that contains the reviewed registry record.
- Written authorization for the observation-only step in section 2 on these
hosts. Use
scripts/observe_rank_local_profile.pyfrom the selected signed observation candidate. Live preflight and the qualification worker require a matching registry record before collecting attestations. - Same-candidate LMS-E2 evidence is collected against the final candidate (section 2, step 5), not against the observation candidate.
- Destructive fault tests are authorized in writing for these hosts.
- For E4, a reviewed capacity model and workload whose retained bytes exceed
both hosts' physical memory (
SC_PAGE_SIZE * SC_PHYS_PAGES). - For E4, a fully bound E4 workload job for
scripts/run_rank_local_qualification.py, following the E4 workload worker. That path is EXPERIMENTAL andnot_qualifieduntil physical E4 evidence is reviewed. - For the fault cases in section 4, a reviewed fault harness that gives each
case a fresh
export_idand an isolated destination. No such harness ships. Without it, run no fault case; the E3 handoff in section 6 then has no fault-case inventories and must say so.
1. Provision the two hosts
-
Rent two distinct physical hosts with one CUDA GPU each. Use the same GPU model, driver, CUDA and software versions on both (the profile is homogeneous). Do not use two VMs on one physical machine; E3 requires distinct physical hosts.
-
Put both hosts on a private network that only these hosts can reach. Gloo and NCCL provide no authentication or encryption.
-
On each host, create local roots owned by the worker user, mode
0700, and disjoint from each other:/local<r>/source-<digest>: the exact offline, read-only, content-addressed model source./local<r>/private-stage: staging.
No shared filesystem is needed or used.
-
Check out the exact candidate read-only on both hosts and run
git verify-commit HEAD.
2. Build and review the exact profile
-
Write a schema v3 profile with exact TP2 geometry (world size 2, local world size 1, coordinator 0) and a
rank_storagesection withscope: "qualification"andtier: "LMS-E3"(later"LMS-E4"). Give each rank its ownsource,stagingand observedstorage_digest(the value ofpreflight.storage_mount_digest(staging)on that host, which the attestation'sstorage_digestmust equal). Fix therendezvous_idnow: host and device digests are keyed by it, so changing it later invalidates the reviewed hardware binding. -
Observation-only step (authorized hosts, no admission). Live preflight cannot produce the attestations for a new profile:
run_preflightcallsconfig_review(config)before it probes either host and refuses while the registry has no matching record. Instead, run the reviewed helper from the preconditions once per host under the launch environment in section 3. On rank 0, run the command below, using the corresponding rank-1 paths on the peer.PYTHONPATH="$PWD" python scripts/observe_rank_local_profile.py \ --profile /local0/profile.json \ --output /local0/private-observations/rank-0.jsonThe output directory must already exist, be worker-owned, mode 0700, and have no symlink components. Existing output files are refused. Retain these review inputs in private storage. The helper verifies the exact selected commit signature with an explicit repository and scrubbed Git environment, and checks package/helper bytes against its signed tree before and after probing. The interpreter, installed dependencies, Git/GPG, import caches and already loaded modules are trusted bootstrap inputs; use a trusted, read-only checkout and runtime. This is not execution attestation. It checks observed profile identities before writing a canonical rank attestation. A publication-indeterminate error requires inspection of private output before retrying; it is not a successful record. Require the helper's exit status 0 before using output as review evidence. Path existence alone is not success or admission: publication may briefly expose bytes before a later failure and rollback, and rollback cannot retract bytes another observer already read. Discard evidence from any failed helper invocation, even if a file remains. The helper uses the same probes as preflight (
SystemProbes().collect(config, launch)and_attestation(config, launch, snapshot)inobliteratus/distributed/preflight.py) and does not callrun_preflight, create an attempt directory, load the model or export. These probes initialize the CUDA driver, select a device (which may create a CUDA context), and query device properties and memory. They perform no explicit tensor allocation or model kernels; driver/runtime initialization may consume device resources. CPU tests mock absent CUDA and do not qualify this physical boundary. From the candidate checkout, runrank_local.review_bindings(config, attestations)on both ranks' attestations to produce the requested bindings. They include each host's physical-memory capacity and theos-sysconf-physical-host-memory-v1domain. The output is a request, not an approval. -
Open a maintainer-reviewed PR, based on current main, that adds the exact
qualificationrecord (profile_id,scope,tier,mapping_digest,policy_digest,bindings,evidence,review) toci/rank-local-profiles.jsonand changes nothing else. The record binds code and policy digests, so compute it in a checkout of that PR's own head, not in the observation candidate:- Set the profile's
code_digesttopreflight.checkout_code_digest()of that checkout. It hashes everyobliteratus/**/*.pyfile, and preflight requires the profile'scode_digestto equal the live checkout's. - Run
rank_local.review_bindings(config, attestations)there, reusing the attestations from step 2. This re-derivescode_digestandadapter_digestfrom that checkout next to the unchangedhardware_digest. - Set the record's
policy_digesttorank_local.policy_digest()there. It hashes the four files inrank_local.POLICY_FILES.
Merge with no intervening change to
obliteratus/**/*.pyor to those policy files: just before merging, confirm thatcheckout_code_digest()andpolicy_digest()of the merge result equal the reviewed values. If main changes either input first, rebase the PR, recompute these values in the new head and have the record re-reviewed. That needs no new observation:hardware_digestdepends on no code or policy input. Only a change of host, device, staging mount, host capacity orrendezvous_idneeds a new observation (and a new authorization for it). Select the merged commit through the trusted manual workflow. This is the final candidate. An edited or untracked registry file is rejected (rank_local.read_review_registry). - Set the profile's
-
Set the profile's
commit_shato the final candidate.commit_shais not a reviewed binding. Leave every other field, including thecode_digestset in step 3, unchanged. -
Collect same-candidate LMS-E2 evidence from the one-host
llama-tp-local-gpulane on the final candidate. Collect E3 (section 3) and E4 (section 5) on that same final candidate.
3. Run E3
-
An already authorized external two-rank scheduler starts one process per host. Each process runs from the final candidate checkout, with that checkout as its working directory and
PYTHONPATH(the worker importstests.conditional).TorchrunEnvironment.from_environinobliteratus/distributed/launcher.pyrequires all of these variables and refuses a run when any is missing or wrong:Variable Value RANK,GROUP_RANK,ROLE_RANK0on the coordinator host,1on the peerLOCAL_RANK0WORLD_SIZE,ROLE_WORLD_SIZE2LOCAL_WORLD_SIZE1MASTER_ADDR,MASTER_PORTthe profile's private, allowlisted numeric endpoint TORCHELASTIC_RUN_IDthe profile's rendezvous_idTORCHELASTIC_RESTART_COUNT,TORCHELASTIC_MAX_RESTARTS0OBLITERATUS_RUN_IDthe profile's run_idGLOO_SOCKET_IFNAME,NCCL_SOCKET_IFNAMEthe profile's network_interfaceEvery other variable, including
CUDA_VISIBLE_DEVICES,PATHandPYTHONPATH, must be listed in the profile'sallowed_environment_keys. Secret- and proxy-bearing names are always rejected.Each process gets its own local job file; no job path is sent to the peer.
_run_workerintests/conditional/test_distributed_llama_tp_cuda.pyreads exactly these job keys:workflow(must be"verify"),profile,candidate_sha(the final candidate),reference,reference_digest,result_directory,external_bindings,source_mount_external_evidence_digest,fixture_digestandmodel_config_digest.run_idandrendezvous_idcome from the profile and the launch environment, not from the job._build_fixturein that file shows the shape. A missing key surfaces only as a refusal before worker admission.JOB=/local0/job.json # this host's own job file; /local1/job.json on rank 1 CUDA_VISIBLE_DEVICES=0 python scripts/run_rank_local_qualification.py --job "$JOB"The worker refuses before admission if the profile is not a reviewed E3 CUDA qualification profile, the checkout is not the selected candidate, or the commit signature fails.
-
Retain
qualification-rank-0.jsonandqualification-rank-1.json, the boundedrank-local-qualification.jsonenvelope, the coordinator'sdistributed-export-manifest.json, the v3 profile and the scheduler logs.
4. Fault and recovery cases (authorized hosts only)
Pending: physical fault collection is blocked until a reviewed harness
exists. The shipped E3 worker hard-codes the export in _export_config() in
tests/conditional/test_distributed_llama_tp_cuda.py: export_id is
"5" * 32 and the output is canonical-output under each rank's staging
root. A new run_id does not change the publication state path
(.<output>.rank-local-state-<export_id>). The shipped worker therefore cannot
give each case a fresh export_id and an isolated destination while it keeps
the prior case's recovery state. Do not run these cases until a reviewed
harness supplies both. The table below is the intended matrix.
Repeat with a fresh run_id and export_id for each case. Never reuse an ID.
| Case | Action | Expected |
|---|---|---|
| Peer death mid-export | Kill rank 1 during replication | Rank 0 errors out, prior output intact, no success |
| Coordinator death at publication | Kill rank 0 after PROMOTION_INTENT and again after COMMIT_DECIDED |
Rank 1 returns LMS_EXPORT_STATE_UNCERTAIN. recovery_inventory() reports outcome uncertain with decision undecided (first kill) or commit (second kill); the fence is kept, and so is the backup if one was taken |
| Network partition | Drop the private link mid-stream | Bounded timeout, both ranks fail closed |
After each kill, inspect the result with
rank_local.recovery_inventory(root, output, export_id) and record its
output. Do not delete a fence to retry; resolving a fence needs maintainer
review.
5. E4
E4 needs a separate reviewed E4 qualification record and the reviewed E4 workload
worker (see preconditions). The workload goes through the public live-session
and export API with budgeted StreamingLlamaReload. The checker rejects E4
unless the measured workload bytes exceed both reviewed host capacities.
6. Offline validation and handoff
Copy the artifacts to a trusted machine. Run the checker from a checkout of the
final candidate with an unedited ci/rank-local-profiles.json: it reads the
registry and policy files from the checkout of the obliteratus package it
imports (rank_local.read_review_registry, rank_local.policy_digest), not
from the evidence. Set PYTHONPATH="$PWD" so that package is this checkout and
not another installed copy. In that checkout:
CANDIDATE_SHA='full-40-hex-final-candidate-sha'
ART=/path/to/retained-artifacts
test "$(git rev-parse HEAD)" = "$CANDIDATE_SHA" && git verify-commit HEAD &&
PYTHONPATH="$PWD" python scripts/check_rank_local_evidence.py --candidate-sha "$CANDIDATE_SHA" \
--config "$ART/profile.json" --evidence "$ART/rank-local-qualification.json" \
--rank-evidence "$ART/qualification-rank-0.json" "$ART/qualification-rank-1.json" \
--manifest "$ART/distributed-export-manifest.json"
Keep the raw artifacts (profile, rank evidence, envelope, manifest, scheduler
logs and inventories) in maintainer-controlled storage. Do not post them to
#287: the profile and logs carry the rendezvous_id that keys the host and
device digests, and private network addresses. Post to #287 only a sanitized
summary: the candidate SHA, the checker output, the SHA-256 of each retained
artifact, the envelope's reviewed digests (config_digest, code_digest,
policy_digest, approval_digest, mapping_digest), and, if the section 4
harness existed, each fault case's inventory outcome, decision and
fence_present. Support is promoted only through a separately reviewed
physical_support registry record that binds same-candidate E2, E3 and E4
digests. Release the rented hosts only after the evidence is retained.