Project

General

Profile

Actions

Bug #5446

closed

System Patches doesn't auto-apply on upgrade from 2.2 to 2.3

Added by Stilez y over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Category:
System Patches
Target version:
Start date:
11/14/2015
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
Affected Version:
2.3
Affected Plus Version:
Affected Architecture:

Description

Backed up my current 2.2.5, installed on a VM, updated to 2.3 alpha (14 Nov), and noticed that none of the patches that were able to be applied against 2.3 and were flagged to auto-apply, were auto-applied.

GUI reported "yes" for auto-apply so it's not a data issue, and they were successfully applied when "apply" was clicked. Unless auto-apply was disabled for the alpha release this seems like a bug.

Actions #1

Updated by Chris Buechler over 8 years ago

  • Project changed from pfSense to pfSense Packages
  • Category set to System Patches
  • Affected Version set to 2.3
Actions #2

Updated by Jim Thompson over 8 years ago

  • Assignee set to Renato Botelho
Actions #3

Updated by Kill Bill over 8 years ago

Well, this uses earlyshellcmd in config.xml. Whatever broke there is an issue in pfSense core very likely, not in package.

Actions #4

Updated by Kill Bill over 8 years ago

Hmmm, and thinking about this, this could have never worked. You upgrade, the packages get removed, then you reboot, the packages get reinstalled. In between there, there's really no way to autoapply the patches on boot.

Actions #5

Updated by Stilez y over 8 years ago

In which case the check for autoapply needs to trigger on post_install as well as earlyshellcmd...?

Actions #6

Updated by Stilez y over 8 years ago

I hadn't noticed autoapply not happening after previous upgrades (2.2.3->2.2.4, 2.2.4->2.2.5) so it looks like something changed

Actions #7

Updated by Kill Bill over 8 years ago

Frankly, I don't think anything at all changed here.

Actions #8

Updated by Renato Botelho over 8 years ago

I could not reproduce the issue. I added a patch, mark it to auto apply, rebooted after an upgrade and it was applied

Actions #9

Updated by Renato Botelho over 8 years ago

Stilez y wrote:

I hadn't noticed autoapply not happening after previous upgrades (2.2.3->2.2.4, 2.2.4->2.2.5) so it looks like something changed

Just to clarify, you claim patches are not auto applied on first boot after upgrade from 2.2 -> 2.3, right? If you reboot your 2.3 system patch is applied during boot, correct?

Actions #10

Updated by Stilez y over 8 years ago

I didn't test that scenario, just noted what happened after the update reboot, as you can see in the screenshots. I didn't further re-reboot to see if that changed anything.

Actions #11

Updated by Renato Botelho over 8 years ago

  • Subject changed from System Patches doesn't auto-apply on current 2.3 to System Patches doesn't auto-apply on upgrade from 2.2 to 2.3

I tried it in lots of different combinations and the only case I can see an issue is during upgrade from 2.2. to 2.3.

What happens in this case is before restart, on 2.2, upgrade process remove all PBIs and set packages to be reinstalled after reboot on 2.3, so during first 2.3 boot, System Patches is not installed and cannot auto apply any patch.

I'm keeping the ticket open to think what could be done in this case

Actions #12

Updated by Jim Pingle over 8 years ago

Honestly we should probably keep this behavior. The likelihood of someone's 2.2.x patch breaking 2.3 in an undesirable way is fairly high, so the fact that it doesn't auto-apply during the upgrade is probably preventing more problems than fixing it would solve.

Actions #13

Updated by Phillip Davis over 8 years ago

Yes, due to the huge changes to the code-base from bootstrap and a whole bunch of code style etc. stuff across /etc /etc/inc and /usr/local/www... I also can't imagine a patch that applies to 2.2.* code that would still apply cleanly to 2.3 anyway. Should be just advertised in the release notes so that people know to review all their system patches after 2.3 upgrade.

Actions #14

Updated by Stilez y over 8 years ago

If it matches the code, then it probably has a fair chance of working. GUI changes above all will break, but those simply won't match the new code anyway, so they won't get auto-applied regardless.

It doesn't seem that likely that a patch will match 2.2.x and also match 2.3, but then works on 2.2.x and breaks 2.3. It's easy to think of examples both ways, but it just doesn't seem that likely (any more than on any other upgrade where auto-apply is enforced and the patch matches).

Maybe just say that that due to the massive changes, system patches created under 2.2 are likely to need review before using, and patches related to GUI output is likely to need rewriting.

Actions #15

Updated by Jim Pingle over 8 years ago

  • Status changed from New to Closed

Closing this since it's safer to just not auto-apply in this case. We'll add notes to docs/upgrade guide if necessary.

Actions

Also available in: Atom PDF