NetBSD Problem Report #60276

From www@netbsd.org  Sun May 17 09:10:04 2026
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits)
	 client-signature RSA-PSS (2048 bits))
	(Client CN "mail.netbsd.org", Issuer "R13" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id D609D1A9239
	for <gnats-bugs@gnats.NetBSD.org>; Sun, 17 May 2026 09:10:03 +0000 (UTC)
Message-Id: <20260517091002.60FFB1A923A@mollari.NetBSD.org>
Date: Sun, 17 May 2026 09:10:02 +0000 (UTC)
From: cryintothebluesky@gmail.com
Reply-To: cryintothebluesky@gmail.com
To: gnats-bugs@NetBSD.org
Subject: Add "Enable sshd" to the sysinst utilities menu
X-Send-Pr-Version: www-1.0
X-From4GNATS: "cryintothebluesky@gmail.com via gnats" <gnats-admin@NetBSD.org>

>Number:         60276
>Category:       install
>Synopsis:       Add "Enable sshd" to the sysinst utilities menu
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    install-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun May 17 09:15:00 +0000 2026
>Originator:     Sad Clouds
>Release:        11.0_RC2
>Organization:
>Environment:
NetBSD  11.0_RC2 NetBSD 11.0_RC2 (GENERIC) #0: Sun Mar  8 10:59:15 UTC 2026  mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC amd64
>Description:
When installing NetBSD, some of us prefer command line to the menu based sysinst. Unfortunately sysinst is a bit buggy (moving between disk partitioning menus can cause it to segfault sometimes) and clunky (confusing workflows, garbled console TUI when kernel messages are logged during install to the same console, etc).

There are several menus: "Utility menu" and "Config menu" with overlapping functionality, i.e. both can run /bin/sh, configure networking, set timezone, etc. For example "Config menu"->"Enable sshd" does not actually enabled sshd in the installer. The presentation of these menus is a bit confusing.

I have personally given up on sysinst and would like NetBSD installer to support a workflow for a manual install via a command line. Some of it can be done via various helper menus in "Utility menu", however one important helper menu is missing: "Enable sshd".

If the installer is running in a console, it is not always possible to copy and paste command lines. For this reason, I tend to enable sshd in the installer and then perform all install and configuration via ssh:

Utility menu -> Run /bin/sh

1. Set root password:
   passwd root

2. Create necessary directories for sshd:
   mkdir -p /var/chroot/sshd

3. Mount /etc/ssh directory. Read-only /etc is mounted on tmpfs via union so we can modify files, but this does not propagate to sub-directories, hence mount /etc/ssh via union so that sshd can create private and public key files on startup:
   mount -t tmpfs -o union tmpfs /etc/ssh

4. Permit root login via ssh:
   sed -i 's/^#PermitRootLogin prohibit-password$/PermitRootLogin yes' /etc/sshd/sshd_config

5. Start sshd:
   /etc/rc.d/sshd onestart

Now we can ssh into the installer, partition disks and extract sets.

It would be nice to automate the above steps with a new menu option.

>How-To-Repeat:

>Fix:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.