Bug 834278 - Anaconda aborts upgrades too early when scriptlet errors occur
Anaconda aborts upgrades too early when scriptlet errors occur
Product: Fedora
Classification: Fedora
Component: fedup (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Will Woods
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-06-21 08:07 EDT by Daniel Thompson
Modified: 2012-11-21 17:49 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-11-21 17:49:49 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Daniel Thompson 2012-06-21 08:07:50 EDT
Description of problem:

During a preupgrade based upgrade from F16 to F17 the installer failed part way through with the following message:
  A script error occured when installing the emacs package. This could indicate
  errors when reading the installation media. Installation cannot continue.

Sure enough in upgrade.log:
  error: %preun(emacs-1:23.3-9.fc16.i686) scriptlet failed, exit status 2

Version-Release number of selected component (if applicable):


How reproducible:

Looks repeatable but due to the disruption of an upgrade reproduction is time

Steps to Reproduce:

1. Install minimal f16 image.
2. Create an alternative version of one of the packages with a bogus preun
   script. Make sure you select a package that has a new version in f17.
3. preupgrade to f17 (probably also affects DVD upgrades when the package
   with the bogus preun script is a core package).

Actual results:

On observing the script error the installer halts entirely part way through
a transaction. No other scripts are run. In particular this means that kernel posttrans scripts (which configures the initrd) do not get run resulting in a unbootable system.

Expected results:

Like yum the script errors should be non-fatal. Especially during upgrade it
is far more damaging to avoid running the other packages scriptlets than it
would be to continue.

Possibly a warning at the end of the upgrade might be justified but I don't think more than that it required. Obviously the emacs package should not have a preun script that can fail. Nevertheless anaconda's overreaction to what should be a non-fatal error has substantial collateral damage.

Additional info:
Comment 1 Chris Lumens 2012-11-21 13:40:20 EST
Reassigning to fedup so Will is aware, though I think he will either end up reassigning this again or closing it out.
Comment 2 Will Woods 2012-11-21 17:49:49 EST
We can't really change F17, since it's been released and is thus frozen. But this should already be fixed in F18, because we're using fedup for upgrades.

fedup downloads and verifies packages *before* the upgrade begins, so there shouldn't be any of those failures *during* the upgrade. 

If there is a non-fatal scriptlet error, the upgrader will just log the error and continue with the upgrade.

(*Fatal* scriptlet errors are still fatal, but that's between RPM and the offending package.)

So. I think this has to be closed as NEXTRELEASE: we can't fix upgrades to F17, but it should work for F18.

If do reproduce the problem in an upgrade to F18, please file a new bug.

Note You need to log in before you can comment on or make changes to this bug.