Project

General

Profile

Bug #11782

reboot -f ends up creating bad /boot/transient.conf

Added by Andy Fiddaman over 1 year ago. Updated over 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
cmd - userland programs
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

A command such as the following:

reboot -f -- "/platform/i86pc/kernel/amd64/unix -B console=ttya" 

causes reboot to invoke uadmin() with boot arguments including a quoted boot path. uadmin calls bootadm:
bootadm -m update_temp -o '/platform/i86pc/kernel/amd64/unix -B zfs-bootfs=rpool/ROOT/20191003,bootpath="/pci@0,0/pci1af4,2@4/blkdev@0,0:b" -B console=ttya'

which creates a /boot/transient.conf file that loader cannot parse due to the quote characters around the bootpath.
% cat /boot/transient.conf
bootfile="/platform/i86pc/kernel/amd64/unix;unix" 
boot-args="-B zfs-bootfs=rpool/ROOT/20191003,bootpath="/pci@0,0/pci1af4,2@4/blkdev@0,0:b" -B console=ttya" 

One place that this occurs is when a stale boot archive is detected during boot. In that case filesystem/usr reboots the system using a command such as this.

Also available in: Atom PDF