Files
makronix/docs/UPDATING.md
T
lotherkandClaude Sonnet 5.5 840782e24c sysinst, media, tests: desktop defaults, four CDs, Portuguese, AHCI test VMs
- sysinst simple mode: sshd on with root login by password, npf firewall,
  mDNS (mdnsd, nsswitch), PulseAudio, CUPS, dbus; extra programs from N
  package CDs (extras.c); cgd root fix (mnt2_mounted)
- Portuguese (pt_BR) catalogs and patch 0013; welcome text for DVD/CDs
- media: console=auto (0008), RAM-disk installer with two CDs (0012),
  package CDs and DVD packages (cd3.sh), userland.sh for the build VM
- tests: line-by-line checks, mDNS pattern, UEFI Enter loop, VMSH_AHCI
  (QEMU 11.1.2 loses PIIX IDE interrupts under load)
- docs: UPDATING.md, npf-default.conf, AGENTS.md updates

Measured 2026-11-07: simple 37 PASS, DVD+sources 42 PASS, cgd BIOS 35 PASS;
cgd UEFI with console=auto not green yet.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-07 21:09:35 +00:00

3.5 KiB

Updating a Makronix system

Written 2026-11-07. What is set up, what is only a plan, and what is not measured. Nothing here has been run on an installed system over time.

Packages

  • Where they come from. The installer writes /etc/pkg_install.conf with PKG_PATH (the NetBSD project's binary repository for the release the packages of the media come from, PKG_REPOSITORY in overlay/usr.sbin/sysinst/setup.c) and CHECK_OS_VERSION=no (the packages are built for NetBSD 11.0, Makronix is 11.99.9: pkg_add would warn about every one). So pkg_add firefox and pkg_add -u work as on any NetBSD.
  • Security. The installer sets fetch_pkg_vulnerabilities=YES in /etc/daily.conf. daily(8) then fetches the vulnerability list (etc/daily:267-275) and security(8) runs pkg_admin audit (etc/security:1096); the report goes to root's mail. That is NetBSD's own mechanism, nothing of ours.
  • What is ours. The makronix set (CDE, vim, flex, git and what they need) is unpacked by sysinst without a package database: pkg_add -u does not update those files, pkg_info does not list them. They change with the next release of Makronix. The extra programs (Firefox, Thunderbird, QEMU) are installed with pkg_add and are registered: those do update.
  • Not measured: pkg_add -u on an installed system, the repository URL after the quarter changes (2026Q4), and what happens when a package of the repository overwrites a file of the makronix set (the install of the extra programs did not conflict, docs/BUILD-VM.md).

The base system

  • A new release comes as new media (make release, make iso); sysinst's "Upgrade NetBSD on a hard disk" unpacks the sets over the system and the administrator runs postinstall and etcupdate as the NetBSD documentation describes (src/usr.sbin/postinstall, src/usr.sbin/etcupdate).
  • Not measured: an upgrade of a Makronix system by sysinst, with or without the makronix set, with the three CDs (the Next-CD menu is in the install path only).
  • On the build VM, make install puts a new build over a running Makronix (installworld).

An encrypted system: the gap

An encrypted installation (cgdroot.c) has a small boot partition, cgd.conf (FFS), with the kernel, cgdroot.kmod, boot.cfg and cgd.conf; the boot loader reads it before the disk is unlocked. /cgdboot in fstab is that partition (noauto). The kernel the system runs from comes from the copy on that partition, not from /netbsd of the root file system.

So a kernel update on an encrypted system is not complete until the new netbsd (and the cgdroot.kmod of the same release) are copied to the boot partition:

mount /cgdboot
cp /netbsd /cgdboot/netbsd
(cp the cgdroot.kmod of the new release to /cgdboot)
umount /cgdboot

This is the procedure by hand, not measured, and nothing does it for the user. sysinst's upgrade path does not unlock a cgd root at all. What is missing, in order of need:

  1. a script on the system that does the copy above (and keeps the old kernel as netbsd.old for the loader's menu), run after every kernel install;
  2. sysinst's upgrade for a cgd root: ask for the passphrase, bring up cgd0, mount, upgrade, and do step 1;
  3. a test: install, upgrade, boot, with the log in build/logs/.

A different route, not decided

sysutils/sysupgrade (pkgsrc) upgrades a NetBSD system in place from the project's binary sets. It would not know the makronix set. Whether Makronix ships its own sysupgrade or relies on media is open.