FreeBSD 11 removed legacy ada aliases, some older installs will fail to mount root post-upgrade
Some upgrade attempts are failing to mount root after the kernel is upgraded to FreeBSD 11.x due to ada disk driver changes.
In the past, ATA disks used
ad device names but later switched to
ada. In FreeBSD 10.x, the
ada driver still allowed the old names to work via legacy aliases. FreeBSD 11.1 no longer provides legacy aliases like it did on 10.x; The kern.cam.ada.legacy_aliases sysctl tunable and related code are gone (See /usr/src/UPDATING entry 20151011). Thus, if an installation still references
ad disks in
/etc/fstab, it will now fail to mount with a current kernel
We have code to switch drives to UFS labels in
/usr/local/sbin/ufslabels.sh but nothing in pfSense-upgrade automatically calls it or checks for the conditions when it may be required. It also has to be run pre-upgrade since it requires
/etc/fstab to be accurate.
Users encountering this issue have a few options:
1. Reinstall and use 'rescue config.xml' in the installer to recover with a fresh install
2. Enter the new disk slice name at the mountroot> prompt,
ufs:/dev/ada0s1a and then adjust /etc/fstab to the new ada0 device names
3. After performing 2, run
/usr/local/sbin/ufslabels.sh to use disk labels instead
/etc/fstab before upgrading and run
/usr/local/sbin/ufslabels.sh if the disks are using adX names.
Updated by Renato Botelho almost 4 years ago
- Status changed from New to Feedback
- % Done changed from 0 to 100
pfSense-upgrade version 0.27_2 on 2.3.x and 0.34 on 2.4.x check for /dev/adN under /etc/fstab and call "/usr/local/sbin/ufslabels.sh commit" to get it fixed before proceed with upgrade
Updated by Jim Pingle almost 4 years ago
- Status changed from Feedback to Assigned
The code itself appears to work but it doesn't get triggered unless you start to run the upgrade from the CLI, stop when prompted, and then re-run pfSense-upgrade.
If you run the upgrade from the GUI or from the shell and immediately use 'y' to continue, it doesn't fix the fstab file.