Project

General

Profile

Actions

Bug #12105

open

Packages are not automatically reinstalled when restoring configuration using the installer

Added by Christian Ullrich 3 months ago. Updated about 1 month ago.

Status:
Feedback
Priority:
Normal
Category:
Package System
Target version:
Start date:
07/04/2021
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
21.09
Release Notes:
Default
Affected Version:
2.5.2
Affected Architecture:

Description

pfSense does not install the configured packages during the first boot after installation if the first documented method of restoring the configuration is used (/conf/config.xml present during installation). It works with the second method (/config/config.xml present at first boot).

In the failing case, the boot process does not print a message about reinstalling packages. Instead, it reports the (absent) packages as successfully started:

Starting package Zabbix Agent 5.2...done.
Starting package Shellcmd...done.

The system.log contains these lines near the end:

Jul 4 18:54:09 hostname php-fpm350: /rc.start_packages: Restarting/Starting all packages.
Jul 4 18:54:09 hostname php-fpm350: /rc.start_packages: The Zabbix Agent 5.2 package is missing its configuration file and must be reinstalled.
Jul 4 18:54:09 hostname check_reload_status389: Syncing firewall
Jul 4 18:54:09 hostname root21926: /etc/rc.d/hostid: WARNING: hostid: unable to figure out a UUID from DMI data, generating a new one
Jul 4 18:54:11 hostname php-fpm350: /rc.start_packages: The Shellcmd package is missing its configuration file and must be reinstalled.
Jul 4 18:54:11 hostname check_reload_status389: Syncing firewall
Jul 4 18:54:11 hostname root85049: Bootup complete
Jul 4 18:54:17 hostname pkg-static20951: pfSense-repo upgraded: 2.5.1 -> 2.5.1_2

pfSense is 2.5.1-RELEASE, the amd64 memstick-serial image.

Actions #1

Updated by Christian Ullrich 3 months ago

Actually, the documentation mentions automatic package reinstallation only for the ECL method, and that is what works for me. If this is working as designed, please pardon the noise.

However, I'm certain that it worked with the other method in the past, too. Didn't it?

Actions #2

Updated by Jim Pingle 3 months ago

Which methods were you testing? Was it loading a config from USB during the installation, or using the "Recover config.xml" choice? Or both?

Actions #3

Updated by Christian Ullrich 3 months ago

Jim Pingle wrote:

Which methods were you testing? Was it loading a config from USB during the installation, or using the "Recover config.xml" choice? Or both?

I'm not concerned about restoring a configuration via the web interface right now; I don't know whether that works.

Regarding the two ways of installing a configuration in the context of installing pfSense, what I found is this:

- If I install with a /conf/config.xml on a second USB memory, this configuration is copied during installation and used on the first reboot. The packages this configuration contains do not get installed, but are reported as successfully started; see above.

- If I install with a /config/config.xml on a second USB memory, this configuration is copied during the first reboot and the packages are installed and started.

Actions #4

Updated by Jim Pingle 3 months ago

  • Status changed from New to Confirmed
  • Target version set to 2.6.0
  • Plus Target Version set to 21.09
  • Affected Version changed from 2.5.1 to 2.5.2

Looks like the base system moved to using /cf/conf/needs_package_sync for the flag file a while back in 10511c3b024620f094146e58acf1ed2f4ea9fa41 but the code in usr.sbin/bsdinstall/scripts/auto in the FreeBSD-src repo is still using the old name needs_package_sync_after_reboot

That path is the same for both "Recover config.xml" and for the case where the config is on a DOS partition during install.

Actions #5

Updated by Renato Botelho about 2 months ago

  • Status changed from Confirmed to Feedback
  • Assignee set to Renato Botelho

Fix pushed and will be present on next round of snapshots

Commit on FreeBSD-src: f5eb50394ce6

Actions #6

Updated by Jim Pingle about 1 month ago

  • Subject changed from Automatic package reinstallation does not happen to Packages are not automatically reinstalled when restoring configuration using the installer

Updating subject for release notes.

Actions

Also available in: Atom PDF