[PATCHES] Import of the NetBSD rc system

190 views
Skip to first unread message

David van Moolenbroek

unread,
Feb 23, 2017, 11:26:15 AM2/23/17
to minix-dev
Another fairly important patch set. We have been wanting to switch over to the NetBSD rc system for a while now, because it is the next natural step in adopting NetBSD userland and makes especially the user configuration part a lot easier. In fact, the NetBSD rc system will be downright required for my network stack replacement project. However, since it is an independent change, I am submitting it separately and a bit earlier here.

In effect, after the switch, you can read the NetBSD documentation on the rc.d system [1] for more information on how things work on MINIX as well.

The switch is not entirely complete: the early stages of the boot process are still driven by the MINIX ramdisk rc script, which starts the NetBSD rc scripts only once the root file system has been mounted. For now, this is just fine: switching over the earlier stage would require resolving a few nasty issues and not buy us anything in practice. The main (post-ramdisk) MINIX rc script is now called from the NetBSD rc infrastructure though, and after that the NetBSD-imported rc scripts get to run. For now, only few rc scripts are imported from NetBSD, but the set will grow soon. The shutdown procedure is now also driven by the NetBSD rc infrastructure.

Please be aware that this change comes with two docs/UPDATING entries. In addition, there is this: for better adherence to how pkgsrc is actually supposed to work, the rc scripts of pkgsrc packages are no longer invoked automatically. For example, this means that if you had previously installed the openssh package, you will now notice that sshd no longer starts automatically. If you want it to, follow the standard pkgsrc procedures: basically, copy /usr/pkg/etc/rc.d/sshd into /etc/rc.d/, and add "sshd=YES" to your /etc/rc.conf . On the upside, the ugly Kerberos warnings at startup are gone.

For MINIX 3 developers it is important to note that the MINIX service(8) utility has been renamed to minix-service(8), because NetBSD has its own service(8) utility. The latter is also imported by this patch set, because it is a pretty convenient interface for the rc.d stuff.

The patch set has been tested with a non-cross build, x86_hdimage, x86_cdimage, x86_ramimage, and arm_sdimage.

Regards,
David

[1] http://www.netbsd.org/docs/guide/en/chap-rc.html

http://gerrit.minix3.org/#/c/3401/ - Rename MINIX service(8) to minix-service(8)
http://gerrit.minix3.org/#/c/3402/ - Import NetBSD rcorder(8)
http://gerrit.minix3.org/#/c/3403/ - Import NetBSD fmt(1)
http://gerrit.minix3.org/#/c/3404/ - Import NetBSD services_mkdb(8)
http://gerrit.minix3.org/#/c/3405/ - VBOX: update current time immediately at startup
http://gerrit.minix3.org/#/c/3406/ - VM: fix race condition communicating with VM
http://gerrit.minix3.org/#/c/3407/ - Initial import of NetBSD rc system
http://gerrit.minix3.org/#/c/3408/ - No longer auto-start pkgsrc packages
http://gerrit.minix3.org/#/c/3409/ - Import NetBSD service(8)

Reply all
Reply to author
Forward
0 new messages