HomeFreeBSD

vmimage.subr: metalog_add generated databases

Description

vmimage.subr: metalog_add generated databases

The files /etc/login.conf.db, /etc/passwd, /etc/pwd.db, /etc/spwd.db,
and /var/db/services.db are generated at install time. When VM images
are built using installworld, there is Makefile code which emits the
necessary METALOG lines; but the pkgbase triggers do not do this. This
resulted in VM images which lacked these essential database files.

VM images are currently the only place where this matters, since this
issue is specific to non-root image builds uusing pkgbase. (In some
point in the future we will start building release ISO iamges from
pkgbase, at which point it will be a problem there as well.)

The long-term solution for this is probably to teach the relevant
database-creating tools to emit METALOG lines; but for now, just log
the necessary files from vmimage.subr.

Reviewed by: dch
MFC after: 5 minutes
Sponsored by: https://www.patreon.com/cperciva
Differential Revision: https://reviews.freebsd.org/D53034

Details

Provenance
cpercivaAuthored on Oct 10 2025, 10:01 PM
Reviewer
dch
Differential Revision
D53034: vmimage.subr: metalog_add generated databases
Parents
rG7a289fe3cd5c: rpc.tlsservd.c: Pin max threads at 1 for now
Branches
Unknown
Tags
Unknown