Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Dec 2025 22:55:54 +0000
From:      Dag-Erling=?utf-8?Q? Sm=C3=B8rg?=rav <des@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 33510b16e663 - stable/14 - nextboot: Reimplement missing -a option
Message-ID:  <693deefa.3cc03.148779ba@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help

The branch stable/14 has been updated by des:

URL: https://cgit.FreeBSD.org/src/commit/?id=33510b16e663bde5be5e4a56ccb17f848c41ef4e

commit 33510b16e663bde5be5e4a56ccb17f848c41ef4e
Author:     Dag-Erling Smørgrav <des@FreeBSD.org>
AuthorDate: 2025-12-13 22:46:25 +0000
Commit:     Dag-Erling Smørgrav <des@FreeBSD.org>
CommitDate: 2025-12-13 22:54:14 +0000

    nextboot: Reimplement missing -a option
    
    PR:             260520
    MFC after:      3 days
    Fixes:          e307eb94ae52 ("loader: zfs should support bootonce an nextboot")
---
 sbin/reboot/nextboot.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/sbin/reboot/nextboot.sh b/sbin/reboot/nextboot.sh
index 0c9cca51eb8d..5b8611b499ab 100644
--- a/sbin/reboot/nextboot.sh
+++ b/sbin/reboot/nextboot.sh
@@ -115,6 +115,10 @@ set -e
 
 nextboot_tmp=$(mktemp $(dirname ${nextboot_file})/nextboot.XXXXXX)
 
+if [ ${append} = "YES" -a -f ${nextboot_file} ]; then
+	cp -f ${nextboot_file} ${nextboot_tmp}
+fi
+
 if [ -n "${zfs}" ]; then
 	zfsbootcfg -z ${zfs} -n freebsd:nvstore -k nextboot_enable -v YES
 	cat >> ${nextboot_tmp} << EOF



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?693deefa.3cc03.148779ba>