Project

General

Profile

Actions

Regression #12517

closed

pfSense-rc console errors on old zfs scheme (zroot)

Added by B C 3 months ago. Updated 3 months ago.

Status:
Resolved
Priority:
High
Assignee:
Category:
Operating System
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
22.01
Release Notes:
Force Exclusion
Affected Version:
Affected Architecture:

Description

After update to 2.6.0.a.20211111.0600 from ~Oct.24-2021 build, and booting with older zfs layout (zroot instead of pfSense), console shows errors:

cannot open 'pfSense': dataset does not exist
cannot open 'pfSense': dataset does not exist
/etc/pfSense-rc: arithmetic expession: expecting primary: " / 2 "
Enter full pathname of shell or RETURN for /bin/sh:

Hitting enter and exiting shell causes a startup loop. Looks to come from these lines in pfSense-rc, around line 460:

if [ -n "${USE_ZFS}" ]; then # Create ZFS reservation
if [ ! -f /.no_zfs_reservation ]; then
zfs list -Hp -o name -t filesystem | grep -q pfSense/reservation
if [ $? -ne 0 ]; then
AVAIL=$( zfs list -Hpo avail pfSense )
RESSIZE=$( zfs list -Hpo avail,used pfSense | awk -v CONVFMT='%.0f' '{printf ( $1 + $2 ) * 0.1 "\n"}' )
if [ $(( ${AVAIL} / 2 )) -gt ${RESSIZE} ]; then
logger "Creating ZFS reservation of ${RESSIZE} bytes"
zfs create -o reservation=${RESSIZE} pfSense/reservation
else
logger "Not enough space to create reservation; ${AVAIL} / 2 is not greater than ${RESSIZE} bytes"
fi
fi
fi
fi

As AVAIL is looking for "pfSense", it is blank where "zroot" is used, therefore reservation calculation fails. "touch /.no_zfs_reservation" does allow for a proper boot.

Actions #1

Updated by Jim Pingle 3 months ago

  • Tracker changed from Bug to Regression
  • Category changed from Upgrade to Operating System
  • Assignee set to Renato Botelho
  • Priority changed from Normal to High
  • Target version set to 2.6.0
  • Plus Target Version set to 22.01
  • Release Notes changed from Default to Force Exclusion
Actions #2

Updated by Brad Davis 3 months ago

  • Status changed from New to Waiting on Merge
  • Assignee changed from Renato Botelho to Brad Davis
Actions #3

Updated by Brad Davis 3 months ago

  • Status changed from Waiting on Merge to Resolved

Thanks for the report. The fix will be in tomorrows snapshot.

Actions

Also available in: Atom PDF