NetBSD Problem Report #59295

From www@netbsd.org  Mon Apr 14 00:22:17 2025
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) server-digest SHA256
	 client-signature RSA-PSS (2048 bits) client-digest SHA256)
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 542C01A9239
	for <gnats-bugs@gnats.NetBSD.org>; Mon, 14 Apr 2025 00:22:17 +0000 (UTC)
Message-Id: <20250414002216.1B94F1A923D@mollari.NetBSD.org>
Date: Mon, 14 Apr 2025 00:22:16 +0000 (UTC)
From: campbell+netbsd@mumble.net
Reply-To: campbell+netbsd@mumble.net
To: gnats-bugs@NetBSD.org
Subject: no reliable way to force reset over console
X-Send-Pr-Version: www-1.0

>Number:         59295
>Category:       kern
>Synopsis:       no reliable way to force reset over console
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Apr 14 00:25:00 +0000 2025
>Originator:     Taylor R Campbell
>Release:        current, 10, 9, ...
>Organization:
The NetBSD Crashandrestartation
>Environment:
>Description:
I routinely wedge machines during kernel development or diagnostics.  When I can _externally_ control the power, e.g. via BMC, I can just reset them or power off and back on again.  But sometimes I don't have that control (and I haven't set up my USB-controlled gadget to turn a wall outlet off and on, not to mention it only fits one device at a time and I haven't bought one that does many devices).

The mechanism for handling break over console should be extremely-super-reliable and provide a way to reset the machine if needed.  But it's not.  On an erlite3, for instance, I recently wound up in this state:

[1]   Segmentation fault (core dumped) "${@}"                                  
[  41.4300027] panic: init died (signal 0, exit 11)                            
[  41.4300027] cpu0: Begin traceback...
[  41.4300027] pid 278510544 not found
[  41.4405921] cpu0: End traceback...
[  41.4405921] kernel: breakpoint trap
Stopped in pid 1.1 (init) at    netbsd:cpu_Debugger+0x4:        jr      ra     
                bdslot: nop
db> reboot
syncing disks... ~~~

Each ~ at the end represents a break I sent over the console with ~# in cu(1).  And it's still sitting there as I type this.
>How-To-Repeat:
get a machine wedged and try to break into ddb or reset it over console
>Fix:
Yes, please!

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.47 2022/09/11 19:34:41 kim Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2025 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.