Skip to content

vms-21a: STARTUP.COM becomes a real STDRV phased startup driver - #286

Merged
baron-3dl merged 2 commits into
mainfrom
vms-21a-startup-phase-driver
Aug 10, 2026
Merged

baron-3dl merged 2 commits into
mainfrom
vms-21a-startup-phase-driver

Conversation

@baron-3dl

Copy link
Copy Markdown
Contributor

Summary

  • STARTUP.COM is now STDRV, a phased startup driver, not a flat script. It reads the nine OBSERVED phase names (verbatim from the Alpha V8.4 oracle capture) from a real SYS$STARTUP:VMS$PHASES.DAT, and for each phase runs the OVMX-defined components registered in SYS$STARTUP:VMS$VMS.DAT (none registered yet — every phase currently runs empty, which is honest) plus the one documented OpenVMS site file this project's reading of the System Manager's Manual assigns to it: SYCONFIG.COM at CONFIG, SYLOGICALS.COM at BASEENVIRON, SYSTARTUP_VMS.COM (unchanged content, only its call site moved) at LPMAIN.
  • SYS$STARTUP is now the measured multi-value search-list logical (DEFINE/SYSTEM SYS$STARTUP dir,SYS$MANAGER) — exactly what vms-420 built DEFINE/SYSTEM multi-value support for. A real [SYS0.SYSCOMMON.SYS$STARTUP] directory backs it (ovmx_layout.h VMS_SYS_STARTUP). OVMX flattens the first element the same way lnm_defaults.c already flattens SYS$MANAGER (off SYS$SYSDEVICE directly, not via a rooted SYS$SYSROOT) — flagged explicitly in STARTUP.COM's own comments as a divergence from the oracle's literal SYS$SYSROOT:[SYS$STARTUP] text.
  • SYS$MANAGER:OVMX.CONF and SYLOGICALS.CONF are deleted — both verified to have zero code readers on main. A real VMS site file is a DCL command procedure, never a KEY=VALUE config file. NODE_NAME already maps to SCSNODE (vms-b6a7, unchanged here); VERSION_LIMIT/DEFAULT_PROTECTION had no live OVMX SYSGEN parameter or SET command to map to, so they're dropped rather than ported to a home that doesn't exist yet.
  • New, minimal, OVMX-authored site files SYCONFIG.COM and SYLOGICALS.COM (the kit packer already listed both as seed-once filenames, anticipating this work).
  • Dockerfile.bootable wired to ship the new [SYS$STARTUP] directory in the FAT initramfs, the OS kit, and the mastered distrib image, with build-time gates asserting the new files are present and the deleted .CONF files are absent from the mastered image.
  • New tests/qemu/test_startup_phase_driver.sh, wired into CI's persistent-boot job.

Clean-room (Rule 8): phase names / file names are OBSERVED (Alpha V8.4 oracle capture, docs/design-boot-faithful.md §3.2/§3.3); VMS$VMS.DAT's line format is an OVMX invention, labeled as such; no VSI .COM/.EXE content was read.

Ground-source proof (real QEMU, real vms.ko + vmsfs.ko)

Ran all three locally against a from-scratch distro/Dockerfile.bootable build (hard timeout-wrapped, no host installs):

  • tests/qemu/test_startup_phase_driver.sh19/19 passed. Boots the mastered distrib image, logs in, and proves against the real running system: SHOW LOGICAL SYS$STARTUP reports the multi-value search list with SYS$MANAGER as its second element; SYS$STARTUP:/SYS$MANAGER: carry the new data/site files; DIRECTORY SYS$MANAGER:OVMX.CONF finds nothing; the LPMAIN-phase site announcement appears; no %RMS-E-FNF/%DCL-E-OPENIN during boot.
  • tests/qemu/test_persistent_boot.sh (mount-or-halt, PRODUCT INSTALL: land a real kit on a real vmsfs volume (vms-df9) #278's norecord-halt regression) — 20/20 passed, no regression.
  • tests/qemu/test_distrib_boot.sh17/17 passed, no regression.

The DCL phase-loop logic itself (OPEN/READ/GOSUB/F$ELEMENT/EOF-via-$STATUS) was also verified standalone against a local build of DCL.EXE before being wired into the shipped file.

Test plan

  • tests/qemu/test_startup_phase_driver.sh (new) — 19/19 in QEMU
  • tests/qemu/test_persistent_boot.sh — 20/20, no regression
  • tests/qemu/test_distrib_boot.sh — 17/17, no regression
  • tests/integration/test_identity_ssot.sh updated to check SYLOGICALS.COM instead of the deleted .CONF
  • CI green on this PR (persistent-boot job runs the new test)

Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com

alice and others added 2 commits August 10, 2026 18:20
Core mechanism, oracle-pinned to the Alpha V8.4 boot capture
(docs/design-boot-faithful.md sec3.2/3.3):

- A real [SYS0.SYSCOMMON.SYS$STARTUP] directory (ovmx_layout.h
  VMS_SYS_STARTUP) carries SYS$STARTUP:VMS$PHASES.DAT (the nine OBSERVED
  phase names verbatim: INITIAL DEVICES PRECONFIG CONFIG BASEENVIRON
  LPBEGIN LPMAIN LPBETA END) and SYS$STARTUP:VMS$VMS.DAT (an OVMX-DEFINED
  component-registration format, Rule 8 -- only the VSI file NAME is
  observed, the line format inside is OVMX's own invention).

- SYS$STARTUP is now the measured multi-value SEARCH LIST logical
  (DEFINE/SYSTEM SYS$STARTUP dir,SYS$MANAGER -- exactly what vms-420
  built DEFINE/SYSTEM multi-value support for). OVMX flattens the first
  element the same way lnm_defaults.c already flattens SYS$MANAGER
  (straight off SYS$SYSDEVICE rather than via a rooted SYS$SYSROOT), and
  STARTUP.COM's own comment flags that divergence from the oracle's
  literal "SYS$SYSROOT:[SYS$STARTUP]" text.

- STARTUP.COM is now a GOSUB-based phase driver (RUN_PHASES): reads
  VMS$PHASES.DAT, and for each phase runs (a) every component
  VMS$VMS.DAT registers for it (RUN_COMPONENTS -- none registered yet,
  so every phase currently runs empty, which is honest per the design
  doc's "empty phases run empty" target) and (b) the one site file this
  project's reading of the OpenVMS System Manager's Manual assigns to
  that phase: SYCONFIG.COM at CONFIG, SYLOGICALS.COM at BASEENVIRON,
  SYSTARTUP_VMS.COM (unchanged content, only its call site moved) at
  LPMAIN. Verified end-to-end against a local build of DCL.EXE (process-
  scope logicals, since SYSTEM-scope needs the real executive) before
  wiring into the shipped file -- OPEN/READ/GOSUB/F$ELEMENT/EOF-via-
  $STATUS all confirmed correct.

- SYS$MANAGER:OVMX.CONF and SYLOGICALS.CONF deleted: both verified to
  have ZERO code readers on main (OVMX.CONF was never referenced by any
  constant; SYLOGICALS.CONF's only reference, VMS_LNM_CONF_PATH, was
  itself dead and is removed). A real VMS site file is a DCL command
  procedure, not a KEY=VALUE config file, per design-boot-faithful.md
  sec2.4. NODE_NAME already maps to SCSNODE (vms-b6a7, unchanged by this
  commit); VERSION_LIMIT/DEFAULT_PROTECTION had no live OVMX SYSGEN
  parameter or SET command to map to, so they are dropped rather than
  ported to a home that doesn't exist yet.

- SYCONFIG.COM and SYLOGICALS.COM are new, minimal, OVMX-authored site
  files (tools/ovmx_kit_pack.c already listed both as seed-once
  filenames, anticipating this work). ovmx_banner.h and
  test_identity_ssot.sh updated to point at SYLOGICALS.COM instead of
  the deleted .CONF.

Dockerfile.bootable/CI wiring for the new directory and a QEMU boot
proof follow in a subsequent commit on this branch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ver boot proof

Dockerfile.bootable: the FAT initramfs, kit-stage, and mastered distrib
image all now carry [SYS0.SYSCOMMON.SYS$STARTUP] (VMS$PHASES.DAT,
VMS$VMS.DAT) alongside the existing SYSEXE/SYSLIB/SYSMGR/SYSHLP/SYSUPD
directories -- without this copy STARTUP.COM's new phase-driver OPENs
fail %RMS-E-FNF on every boot. Added build-time gates on the mastered
distrib image: VMS$PHASES.DAT/VMS$VMS.DAT/SYCONFIG.COM/SYLOGICALS.COM
must be present, and OVMX.CONF/SYLOGICALS.CONF must NOT be -- a
regression that recreates either deleted file now fails the build, not
just a runtime check.

tests/qemu/test_startup_phase_driver.sh (new): boots the pre-installed
distribution disk, logs in over the console, and proves against the
REAL running system (not a build-time inspection) that SHOW LOGICAL
SYS$STARTUP reports the measured multi-value search list (SYS$MANAGER
as its second element -- vms-420's multi-value DEFINE/SYSTEM actually
ran at boot), SYS$STARTUP:/SYS$MANAGER: carry the new data/site files,
and DIRECTORY SYS$MANAGER:OVMX.CONF finds nothing on the booted,
mounted disk. Also checks the pre-login boot console for the
LPMAIN-phase site announcement and the absence of %RMS-E-FNF/
%DCL-E-OPENIN during boot (scoped to the boot-only log segment, so the
later intentional OVMX.CONF absence-check can't be mistaken for a
regression). Registered in ci.yml's persistent-boot job, right after
the existing distrib-boot test it reuses the built image from.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@baron-3dl
baron-3dl merged commit 024aa20 into main Aug 10, 2026
53 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant